$this->uadata['eng_version'] = $regs[3];
$this->mobile = ($regs[2] == 'Mobile');
}
- elseif (preg_match('|Mozilla/5.0 \(Mobile; [^;]+; rv:([^\);]+)\)|', $this->uastring, $regs)) {
+ elseif (preg_match('#Mozilla/5.0 \((Mobile|Tablet); [^;]+; rv:([^\);]+)\)#', $this->uastring, $regs)) {
$this->uadata['os'] = 'Firefox OS';
$this->uadata['lang'] = null;
- $this->uadata['eng_version'] = $regs[1];
- $this->mobile = true;
+ $this->uadata['eng_version'] = $regs[2];
+ $this->mobile = ($regs[1] == 'Mobile');
}
elseif (preg_match('|Mozilla/5.0 \(([^;]+); ([^;]+); rv:([^\);]+)\)|', $this->uastring, $regs)) {
if ((strpos($regs[2], 'Linux') !== false) && ($regs[1] != 'X11')) {
$this->uadata['lang'] = null;
$this->uadata['eng_version'] = null;
}
- elseif (preg_match('|Mozilla/5.0 \(Mobile; rv:([^\);]+)\)|', $this->uastring, $regs)) {
+ elseif (preg_match('#Mozilla/5.0 \((Mobile|Tablet); rv:([^\);]+)\)#', $this->uastring, $regs)) {
$this->uadata['os'] = 'Firefox OS';
$this->uadata['lang'] = null;
- $this->uadata['eng_version'] = $regs[1];
- $this->mobile = true;
+ $this->uadata['eng_version'] = $regs[2];
+ $this->mobile = ($regs[1] == 'Mobile');
}
elseif (preg_match('|Mozilla/5.0 \(([^;]+); rv:([^\);]+)\)|', $this->uastring, $regs)) {
$this->uadata['os'] = $regs[1];