PHP判断是否为IE
is_ie()函数判断浏览器是否是IE内核
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
<?php function is_ie() { $useragent = strtolower($_SERVER['HTTP_USER_AGENT']); if((strpos($useragent, 'opera') !== false) || (strpos($useragent, 'konqueror') !== false)) return false; if(strpos($useragent, 'msie ') !== false) return true; return false; } if(is_ie()){ echo '这是IE'; }else{ echo '这不是IE'; } |
- PHP函数获取来源IP
- js获取url参数值