3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php if(preg_match('/MSIE (.*?);/', "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)" ) || preg_match('/^(?=.*(Trident))(?=.*(rv:11.0)).*$/', "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)" )) { $url = 'IE detected'; } else { $url = 'not detected'; } echo $url;
Output for 5.3.7 - 7.2.0
IE detected