Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-25-2008, 04:12 PM
Member
 
Join Date: Oct 2008
Posts: 5
Rep Power: 0
wwuster is on a distinguished road
Default System.setProperty("http.agent"..) appends Java/1.6
In my JAVA program I set the user agent with
System.setProperty("http.agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)");

But I see from packet sniffing that JAVA appends " Java/1.6" to the user agent that I'm trying to set.

This causes a web page that I am trying to read to stop responding.

Does anyone know how to get around this?

thanks,
William
Bookmark Post in Technorati
Reply With Quote
  #2 (permalink)  
Old 10-25-2008, 04:20 PM
Eranga's Avatar
Moderator
 
Join Date: Jul 2007
Location: Colombo, Sri Lanka
Posts: 7,523
Rep Power: 11
Eranga has a spectacular aura aboutEranga has a spectacular aura about
Send a message via Yahoo to Eranga
Default
Check the "http.agent" value before set the property. May be somewhere within your application it can be appended, system cannot append that as far as I know.
__________________
Use an appropriate Subject. "Help, urgent!" isn't one.
Someone helped you? their helpful post.
Help:Forums FAQ|How To Ask Questions The Smart WayResources:The Java Tutorials|Glossary for Java|NetBeans IDE|Sun DownloadsWeb:WritOnceTips:Is your IDE the best?|Which Application Server?
Bookmark Post in Technorati
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
the dollar sign "$", prints like any other normal char in java like "a" or "*" ? lse123 New To Java 1 10-20-2008 08:35 AM
<core:forEach var="" begin="+<%=j%>+">??? freddieMaize JavaServer Pages (JSP) and JSTL 1 09-27-2008 02:20 AM
System.out.print("Hello!") Console Introductions 6 09-22-2008 01:09 AM
[SOLVED] HELP! Is this BUG? System.out.println() always shows &quot;@9304b1&quot; dark_cybernetics New To Java 11 08-19-2008 12:29 PM
"Jumble" or "Scramble" Program Shadow22202 Java Applets 8 04-30-2008 04:42 AM


All times are GMT +2. The time now is 07:50 AM.



VBulletin, Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2009, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org