Changeset 2995

Show
Ignore:
Timestamp:
07/08/2008 02:36:45 AM (3 months ago)
Author:
Geert
Message:

Fixing #541. Allowing for letters in versions. Also added a few browsers.

Location:
trunk/system
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/system/config/user_agents.php

    r2376 r2995  
    4747        'hp-ux'          => 'HP-UX', 
    4848        'hurd'           => 'GNU/Hurd', 
    49         'unix'           => 'Unknown Unix OS' 
     49        'unix'           => 'Unknown Unix OS', 
    5050); 
    5151 
     
    6767        'Safari'            => 'Safari', 
    6868        'Konqueror'         => 'Konqueror', 
     69        'Epiphany'          => 'Epiphany', 
     70        'Galeon'            => 'Galeon', 
    6971        'Mozilla'           => 'Mozilla', 
    7072        'icab'              => 'iCab', 
     
    7375        'hotjava'           => 'HotJava', 
    7476        'amaya'             => 'Amaya', 
    75         'IBrowse'           => 'IBrowse' 
     77        'IBrowse'           => 'IBrowse', 
    7678); 
    7779 
     
    9193        'ericsson'       => 'Ericsson', 
    9294        'blackBerry'     => 'BlackBerry', 
    93         'motorola'       => 'Motorola' 
     95        'motorola'       => 'Motorola', 
    9496); 
    9597 
     
    104106        'fastcrawler' => 'FastCrawler', 
    105107        'infoseek'    => 'InfoSeek Robot 1.0', 
    106         'lycos'       => 'Lycos' 
     108        'lycos'       => 'Lycos', 
    107109); 
  • trunk/system/core/Kohana.php

    r2981 r2995  
    12071207                                        if (stripos(Kohana::$user_agent, $agent) !== FALSE) 
    12081208                                        { 
    1209                                                 if ($type === 'browser' AND preg_match('|'.preg_quote($agent).'[^0-9.]*+([0-9.]+)|i', Kohana::$user_agent, $match)) 
     1209                                                if ($type === 'browser' AND preg_match('|'.preg_quote($agent).'[^0-9.]*+([0-9.][0-9.a-z]*)|i', Kohana::$user_agent, $match)) 
    12101210                                                { 
    12111211                                                        // Set the browser version