*/
class Probe {
+ private static $baseurl;
+
/**
* @brief Rearrange the array so that it always has the same order
*
$ssl_url = "https://".$host."/.well-known/host-meta";
$url = "http://".$host."/.well-known/host-meta";
+ $baseurl = "http://".$host;
+
$xrd_timeout = Config::get('system','xrd_timeout', 20);
$redirects = 0;
elseif ($attributes["rel"] == "lrdd")
$xrd_data["lrdd"] = $attributes["template"];
}
+
+ self::$baseurl = $baseurl;
+
return $xrd_data;
}
$data['nick'] = trim(substr($data['nick'], 0, strpos($data['nick'], ' ')));
}
- if (!isset($data["network"]))
+ if (self::$baseurl != "") {
+ $data["baseurl"] = self::$baseurl;
+ }
+
+ if (!isset($data["network"])) {
$data["network"] = NETWORK_PHANTOM;
+ }
$data = self::rearrange_data($data);
dbesc(normalise_link($data['url']))
);
}
+
return $data;
}