PHP 7 gives me a notice about HTTP_ACCEPT
-
Undefined index: HTTP_ACCEPT in /plugins/dynamic-to-top/inc/dynamic-to-top-class.php on line 440
In the function to check if the browser is mobile, the line on 440 is
if( preg_match( "/wap\.|\.wap/i", $_SERVER["HTTP_ACCEPT"] ) ) return true;
I checked the PHP Manual and HTTP_ACCEPT is a correct element for $_SERVER but the manual didn’t find wap. What needs to be changed in the function?
- The topic ‘PHP 7 gives me a notice about HTTP_ACCEPT’ is closed to new replies.