+ $networkname = str_replace($search, $replace, $s);
+
+ if ((in_array($s, array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) && ($profile != "")) {
+ $r = dba::fetch_first("SELECT `gserver`.`platform` FROM `gcontact`
+ INNER JOIN `gserver` ON `gserver`.`nurl` = `gcontact`.`server_url`
+ WHERE `gcontact`.`nurl` = ? AND `platform` != ''", normalise_link($profile));
+
+ if (dbm::is_result($r)) {
+ $networkname = $r['platform'];
+ }
+ }