Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can I detect IE6 with PHP?

Is there a way to use PHP to detect if the page is being loaded using IE6?

like image 513
PHLAK Avatar asked Mar 23 '09 00:03

PHLAK


People also ask

How does Chrome detect PHP browser?

PHP has built in get_browser() function to get browser and platform.

How do I test IE7?

Press F12 and select IE7 from the Browser Mode dropdown.


1 Answers

Try checking their user agent for 'MSIE 6.'.

$using_ie6 = (strpos($_SERVER['HTTP_USER_AGENT'], 'MSIE 6.') !== FALSE); 

This is based on this user agent information.

like image 98
Paige Ruten Avatar answered Oct 04 '22 04:10

Paige Ruten