X-Git-Url: http://git.polytechnique.org/?a=blobdiff_plain;ds=sidebyside;f=scripts%2Fwebredirect.php;h=f834e07b8df93c042af5b833a86b8d7506b0ae98;hb=5b4598828acca724080fb36c1f13b30e95b7e891;hp=1db58e4bd340311339fc9b1d5e79fd34c6d2e74f;hpb=fa36e5264c28077f3f7c6ea30f5edbd323401a72;p=platal.git diff --git a/scripts/webredirect.php b/scripts/webredirect.php index 1db58e4..f834e07 100644 --- a/scripts/webredirect.php +++ b/scripts/webredirect.php @@ -1,6 +1,6 @@ xdb->query( +$res = XDB::query( "SELECT redirecturl FROM auth_user_quick AS a INNER JOIN aliases AS al ON (al.id = a.user_id AND (al.type='a_vie' OR al.type='alias')) @@ -35,9 +35,9 @@ $res = $globals->xdb->query( if ($url = $res->fetchOneCell()) { $url = preg_replace('@/+$@', '', $url); if($path) { - redirect("http://$url/$path"); + http_redirect("http://$url/$path"); } else { - redirect("http://$url"); + http_redirect("http://$url"); } exit(); }