Professional Web Applications Themes

How can I emulate my browsers HTTP_USER_AGENT? - PHP Development

Folks, I use Apache/PHP with Webazlier to view the log files. I get a number of user agents (web browsers?) that visit the website - For example: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1 Mozilla/4.0 (compatible; MSIE 5.5; Windows 98; Win 9x 4.90) Mozilla/2.0 (compatible; T-H-U-N-D-E-R-S-T-O-N-E) Googlebot/2.1 (+[url]http://www.googlebot.com/bot.html[/url]) Mozilla/3.0 (compatible; Indy Library) ia_archiver SurveyBot/2.2 KaHT How can I change my http user agent - either via a unix shell script or PHP to give the same results for my search engine/crawler? Thanks in advance, Randell D....

  1. #1

    Default How can I emulate my browsers HTTP_USER_AGENT?


    Folks,

    I use Apache/PHP with Webazlier to view the log files. I get a number of
    user agents (web browsers?) that visit the website - For example:

    Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1
    Mozilla/4.0 (compatible; MSIE 5.5; Windows 98; Win 9x 4.90)
    Mozilla/2.0 (compatible; T-H-U-N-D-E-R-S-T-O-N-E)
    Googlebot/2.1 (+[url]http://www.googlebot.com/bot.html[/url])
    Mozilla/3.0 (compatible; Indy Library)
    ia_archiver
    SurveyBot/2.2
    KaHT

    How can I change my http user agent - either via a unix shell script or PHP
    to give the same results for my search engine/crawler?

    Thanks in advance,
    Randell D.


    Randell D. Guest

  2. #2

    Default Re: How can I emulate my browsers HTTP_USER_AGENT?

    Randell D. wrote:
    > How can I change my http user agent - either via a unix shell script or
    > PHP to give the same results for my search engine/crawler?
    Depends entirely on the client you're using. In Konqueror it's in the
    options menu. With curl it's --user-agent 'STRING', with wget it's
    --user-agent='STRING', etc., etc.


    --
    ----- stephan beal
    Registered Linux User #71917 [url]http://counter.li.org[/url]
    I speak for myself, not my employer. Contents may
    be hot. Slippery when wet. Reading disclaimers makes
    you go blind. Writing them is worse. You have been Warned.

    stephan beal Guest

Similar Threads

  1. Using #cgi.HTTP_USER_AGENT#
    By weswhite7 in forum Coldfusion - Advanced Techniques
    Replies: 1
    Last Post: May 24th, 08:34 AM
  2. How to emulate F5 (Refresh) for the currently editeddoent?
    By harpo_ in forum Macromedia Exchange Dreamweaver Extensions
    Replies: 3
    Last Post: March 21st, 10:27 AM
  3. $HTTP_USER_AGENT content
    By Krzysztof Piotrowski in forum PHP Development
    Replies: 3
    Last Post: May 1st, 01:56 PM
  4. Emulate perls local
    By Karsten Meier in forum Ruby
    Replies: 4
    Last Post: September 9th, 09:07 PM
  5. [PHP] Parsing HTTP_USER_AGENT
    By Haj in forum PHP Development
    Replies: 0
    Last Post: August 17th, 06:43 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139