You are here

public function purl_useragent::detect in Persistent URL 7

Same name and namespace in other branches
  1. 6 includes/purl_useragent.inc \purl_useragent::detect()

Detect the the processor value for the current page request

Return value

value that can be pased to the parse step.

Overrides purl_processor::detect

File

includes/purl_useragent.inc, line 17

Class

purl_useragent
User agent style.

Code

public function detect($q) {
  $useragent = $_SERVER['HTTP_USER_AGENT'];
  if (!empty($useragent)) {
    return $useragent;
  }
  return '';
}