2012-06-03 03:05:23 +02:00
|
|
|
<?php
|
|
|
|
|
2017-04-30 06:07:00 +02:00
|
|
|
use Friendica\App;
|
2017-11-07 03:22:52 +01:00
|
|
|
use Friendica\Network\Probe;
|
2012-06-03 03:05:23 +02:00
|
|
|
|
2017-01-09 13:12:54 +01:00
|
|
|
function acctlink_init(App $a) {
|
2016-02-07 15:11:34 +01:00
|
|
|
|
2017-03-21 17:02:59 +01:00
|
|
|
if(x($_GET,'addr')) {
|
2012-06-03 03:05:23 +02:00
|
|
|
$addr = trim($_GET['addr']);
|
2017-11-07 03:22:52 +01:00
|
|
|
$res = Probe::uri($addr);
|
2012-06-03 03:05:23 +02:00
|
|
|
//logger('acctlink: ' . print_r($res,true));
|
2017-03-21 17:02:59 +01:00
|
|
|
if($res['url']) {
|
2012-06-03 03:05:23 +02:00
|
|
|
goaway($res['url']);
|
|
|
|
killme();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|