denoteone Posted September 7, 2010 Share Posted September 7, 2010 I am using a nivo slider that doesn't work in IE 6. I am trying to think of the best way to verify the users browser and if it is IE 6 show a static image anything else show slider. Is PHP the best way to accomplish this? Link to comment https://forums.phpfreaks.com/topic/212724-get-user-browser-for-if-statement/ Share on other sites More sharing options...
petroz Posted September 7, 2010 Share Posted September 7, 2010 PHP will prob be the most reliable method as not everyone has javascript enabled... You could do something like this.. Havent tested this as I refuse to run anything on a PC... Sorry! <?php $useragent = $_SERVER['HTTP_USER_AGENT']; $ie6 = "MSIE 6."; $is_ie6 = strpos($useragent,$ie6); if($is_ie6 == 'true'){ echo "Ooops, your feel into a time machine and are running IE6!"; } Link to comment https://forums.phpfreaks.com/topic/212724-get-user-browser-for-if-statement/#findComment-1108140 Share on other sites More sharing options...
Rifts Posted September 7, 2010 Share Posted September 7, 2010 echo "Ooops, your feel into a time machine and are running IE6!"; lol at that line Link to comment https://forums.phpfreaks.com/topic/212724-get-user-browser-for-if-statement/#findComment-1108159 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.