473,416 Members | 1,983 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,416 software developers and data experts.

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 (+http://www.googlebot.com/bot.html)
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.
Jul 16 '05 #1
1 3130
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 http://counter.li.org
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.

Jul 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Sims | last post by:
Hi, if i use... // php $info = getenv("HTTP_USER_AGENT"); // I noticed that Mozzila and Netscape <6(?) both use the same Agent. // so i was thinking of if...
4
by: Daniel Orner | last post by:
Does anyone know of a simple way to have a Python script find out what browser is accessing it? After a web search the only thing I found to do this is Zope, but the system I'm programming doesn't...
12
by: tomasio | last post by:
Dear Group, I managed to simulate framelike behaviour in mozilla-based browsers by now, but it doesn't work out with Internet Explorer 6. Could someone glance through the code on the...
61
by: /* frank */ | last post by:
I have to do a homework: make a CPU simulator using C language. I have a set of asm instructions so I have to write a program that should: - load .asm file - view .asm file - do a step by step...
7
by: Marcus | last post by:
I have read quite a few articles on "fingerprinting" a user when they start a session. Chris Shiflett has a good article here: http://shiflett.org/articles/the-truth-about-sessions However,...
2
by: Andre-John Mas | last post by:
Hi, I am trying to create a web page that has three sections: header, left frame and right frame: --------------------------- | | --------------------------- | ...
7
by: patelxxx | last post by:
When I run the code below, the $ENV{'HTTP_USER_AGENT'} is coming up blank, I'm saved the file under .pl and .cgi extensions and still I can't display the browser name. For this reason the code...
14
by: Eugeny Myunster | last post by:
Hello all, How can i emulate sizeof() only for integers?
3
by: Paulo | last post by:
Can asp detect what browser the user is running? Any fix should be done for each one?
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.