diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2008-11-17 17:33:40 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2008-11-17 17:33:40 +0000 |
commit | e06f19fa3b42cf29d5e0a6584d09fcc1d9a07244 (patch) | |
tree | 6d10f46cc7a6d7fa3deb5066d7d70efaa570976d /usr/local/www/head.inc | |
parent | caf7d0bc3914824210dfa48ecb027b528dcc7436 (diff) | |
download | pfsense-e06f19fa3b42cf29d5e0a6584d09fcc1d9a07244.zip pfsense-e06f19fa3b42cf29d5e0a6584d09fcc1d9a07244.tar.gz |
Detect iphone / ipod
Diffstat (limited to 'usr/local/www/head.inc')
-rwxr-xr-x | usr/local/www/head.inc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/usr/local/www/head.inc b/usr/local/www/head.inc index 4c9f61c..ee45ace 100755 --- a/usr/local/www/head.inc +++ b/usr/local/www/head.inc @@ -8,6 +8,15 @@ if($config['theme'] <> "") else $g['theme'] = "pfsense"; +/* + * If this device is an apple ipod/iphone + * switch the theme to one that works with it. + */ +$apple_ua = array("iPhone","iPod"); +foreach($apple_ua as $useragent) + if(strstr($_SERVER['HTTP_USER_AGENT'], $useragent)) + $g['theme'] = "pfsense"; + $pagetitle = gentitle( $pgtitle ); ?> |