
06-17-2009, 02:07 PM
|
|
|
Join Date: Feb 2003
Location: Iowa
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by MSC James
Assuming the iPhone supports JavaScript redirects (hopefully it does but I dont have one to test), this should help
Edit the template of your normal navbar template with the following (if you already have his detector javascript in there, remove it).
Code:
<script type="text/javascript">
if ((navigator.userAgent.indexOf('iPhone') != -1) ||
(navigator.userAgent.indexOf('iPod') != -1)) {
window.location.href = "$_SERVER[PHP_SELF]?<if condition="$_SERVER['QUERY_STRING']">$_SERVER[QUERY_STRING]&</if>styleid=XX";
}
</script>
Replace XX with the iPhone styleID
|
Or just use Dartho's Mobile Phone / iPhone / PDA Detection and Style Assignment addon.
--JOsh
|