Re: Html download challenge
- From: "Paul Battersby" <batman42ca@xxxxxxxx>
- Date: Thu, 30 Jun 2005 17:41:55 -0400
Yes, I did this:
System.setProperty("http.agent", "Test/1.0" +
"(" + System.getProperty("os.name") + ")");
and it worked.
"Patrick May" <pjm@xxxxxxx> wrote in message
news:m2u0jfva1v.fsf@xxxxxxxxxxxxxxxxxxxxxxxxxx
> "Paul Battersby" <batman42ca@xxxxxxxx> writes:
> > Here is some sample code. You will see me loading from 2 urls. The
> > first one works. The second (the one I care about) does not even
> > though my browser (Internet Explorer) has no trouble with the url.
>
> I ran this against the RequestHeaderExample servlet provided with
> Tomcat and got the following:
>
> user-agent Java/1.5.0_02
> host localhost:8080
> accept text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
> connection keep-alive
> content-type application/x-www-form-urlencoded
>
> Evidently the Java classes you're using are setting these defaults
> and, as noted in other replies, Google doesn't like the user agent.
>
> Regards,
>
> Patrick
>
> ------------------------------------------------------------------------
> S P Engineering, Inc. | The experts in large scale distributed OO
> | systems design and implementation.
> pjm@xxxxxxx | (C++, Java, Common Lisp, Jini, CORBA, UML)
.
- Prev by Date: java.lang.UnsatisfiedLinkError:isNetworkMonitorActive
- Next by Date: Re: Struts question <html:text>
- Previous by thread: java.lang.UnsatisfiedLinkError:isNetworkMonitorActive
- Next by thread: Re: Html download challenge
- Index(es):
Relevant Pages
|