protected static httpUserAgent ( ) : string | ||
return | string | The user agent string |
protected static function httpUserAgent()
{
$ua = strip_tags($_SERVER['HTTP_USER_AGENT']);
$ua = preg_replace('/javascript|vbscri?pt|script|applet|alert|document|write|cookie/i', '', $ua);
return substr($ua, 0, 255);
}