PHP UserAgent detection

Discussion in 'General Software Discussion' started by UberLord, Aug 15, 2002.

  1. UberLord

    UberLord A Legend in Underwear

    Joined:
    May 8, 2002
    Messages:
    5,255
    Likes Received:
    4
    Trophy Points:
    0
    I've posted my PHP code that detects browser and platform.
    I've tested in on every browser/platform that I and my friends have - which is a fair bit.

    But there's code to test for obscure browsers and platforms which may work but I haven't tested. However, I did look to see how some similar code worked and implemented similar stuff.

    It's licenced under the LPGL, so feel free to use it however you want.

    Download it from here

    The zip contains 2 files.

    ua.php - the detection code
    browserosinfo.php - a sample page that demonstrates how to use it.

    Requirements
    PHP 4.x

    Notes
    Must be run against a webserver - it won't work simply opening the file in a browser (but hey - you already knew that ;) )

    Enjoy guys :)
     
  2. Malus

    Malus BSD SMASH!

    Joined:
    May 13, 2002
    Messages:
    1,170
    Likes Received:
    3
    Trophy Points:
    0
    :D

    I'll try this out when I get the chance.
     

Share This Page

visited