summaryrefslogtreecommitdiffstats
path: root/usr/local/www/head.inc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2010-10-19 15:34:35 -0400
committerjim-p <jimp@pfsense.org>2010-10-19 15:34:35 -0400
commitd7381e715d716a26f4a139edfaa2cb2f63d0ba5e (patch)
treeb88ada0fed903c60235b3b538f46c2aaf8890ca9 /usr/local/www/head.inc
parentf2a86ca96fb8e49d978679dab4cfad6ce2f0d9f4 (diff)
downloadpfsense-d7381e715d716a26f4a139edfaa2cb2f63d0ba5e.zip
pfsense-d7381e715d716a26f4a139edfaa2cb2f63d0ba5e.tar.gz
Generalize the "low res" user agent detection so it isn't Apple-specific. Include Android in the detection, and also provide a mechanism so that the "low res" theme can be set in globals.inc.
Diffstat (limited to 'usr/local/www/head.inc')
-rwxr-xr-xusr/local/www/head.inc6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/local/www/head.inc b/usr/local/www/head.inc
index 12f38b8..e4a7a95 100755
--- a/usr/local/www/head.inc
+++ b/usr/local/www/head.inc
@@ -16,10 +16,10 @@ else
* If this device is an apple ipod/iphone
* switch the theme to one that works with it.
*/
-$apple_ua = array("iPhone","iPod", "iPad");
-foreach($apple_ua as $useragent)
+$lowres_ua = array("iPhone","iPod", "iPad", "Android");
+foreach($lowres_ua as $useragent)
if(strstr($_SERVER['HTTP_USER_AGENT'], $useragent))
- $g['theme'] = "pfsense";
+ $g['theme'] = empty($g['theme_lowres']) ? "pfsense" : $g['theme_lowres'];
$pagetitle = gentitle( $pgtitle );
OpenPOWER on IntegriCloud