ccrevcypsys Posted October 24, 2007 Share Posted October 24, 2007 What code do i use to find what kind of browser someone is using??? Link to comment https://forums.phpfreaks.com/topic/74640-solved-finding-the-browser/ Share on other sites More sharing options...
rlindauer Posted October 24, 2007 Share Posted October 24, 2007 Javascript: http://www.quirksmode.org/js/detect.html Link to comment https://forums.phpfreaks.com/topic/74640-solved-finding-the-browser/#findComment-377268 Share on other sites More sharing options...
The Little Guy Posted October 24, 2007 Share Posted October 24, 2007 echo $_SERVER['HTTP_USER_AGENT']; Link to comment https://forums.phpfreaks.com/topic/74640-solved-finding-the-browser/#findComment-377270 Share on other sites More sharing options...
ccrevcypsys Posted October 24, 2007 Author Share Posted October 24, 2007 now if i want to use this to make an if statement what would i do. i need to do something if it is ie and it is different than moz? Link to comment https://forums.phpfreaks.com/topic/74640-solved-finding-the-browser/#findComment-377276 Share on other sites More sharing options...
The Little Guy Posted October 24, 2007 Share Posted October 24, 2007 <?php if(preg_match("~MSIE~",$_SERVER['HTTP_USER_AGENT'])){ echo 'This is Microsoft Internet Explorer'; }else{ echo 'This is Mozilla FireFox'; } ?> Link to comment https://forums.phpfreaks.com/topic/74640-solved-finding-the-browser/#findComment-377279 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.