index : archweb32 | |
Archlinux32 website | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | packages/pkginfo.php | 4 |
diff --git a/packages/pkginfo.php b/packages/pkginfo.php index eac3b09..8265bc7 100644 --- a/packages/pkginfo.php +++ b/packages/pkginfo.php @@ -8,7 +8,9 @@ require_once BASE . "/lib/style.php"; $memcache = new Memcache; $memcache -> connect('localhost', 11211) or die ('Memcached Connection Error'); $pkgapi_reachable = $memcache -> get('pkgapi_reachable'); - $tld = array_pop((explode('.', $_SERVER['HTTP_HOST']))); + $tld = explode('.', $_SERVER['HTTP_HOST']); + end($tld); + $tld = current($tld); if (array_key_exists('HTTPS', $_SERVER) && ($_SERVER['HTTPS'] == 'on')) $protocol = 'https'; else |