3 use Friendica\Network\Probe;
7 * PROBE_DIASPORA has a bias towards returning Diaspora information
8 * while PROBE_NORMAL has a bias towards dfrn/zot - in the case where
9 * an address (such as a Friendica address) supports more than one type
13 define('PROBE_NORMAL', 0);
14 define('PROBE_DIASPORA', 1);
17 * @brief Probes a network address to discover what kind of protocols we need to communicate with it.
19 * Warning: this function is a bit touchy and there are some subtle dependencies within the logic flow.
22 * @deprecated Use Friendica\Network\Probe instead
24 * @see Friendica\Network\Probe::uri()
26 * @param string $url Any URI
27 * @param int $mode One of the PROBE_* constants
28 * @return array Same data array returned by Friendica\Network\Probe::uri()
30 function probe_url($url, $mode = PROBE_NORMAL) {
32 if ($mode == PROBE_DIASPORA) {
33 $network = NETWORK_DIASPORA;
38 $data = Probe::uri($url, $network);