commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mattias J <>
Subject Re: HttpClient and User Agent string
Date Fri, 20 May 2005 09:31:17 GMT
At 2005-05-20 08:10, you wrote:
>At 2005-05-20 00:32, you wrote:
>>the archives contain traces of a HttpClient specific dev mailing list, 
>>but it does not seem to exist anymore, so I wonder if this is the right 
>>place to ask.
>>I need to build some HTTP utilities. Jakarta HttpClient seemed
>>to do the job apparently, but I can't find a way to change the
>>user-agent header!!!
>>reading the JavaDocs I got as far as:
>>getmethod = new GetMethod(url_to_get);
>>Header ua = new Header("User-Agent","Mozilla/5.0 (Macintosh; U; PPC Mac 
>>OS X; en)");
>>getmethod.USER_AGENT = ua;
>>Alas, for reasons I can't understand, this is not permitted:
>What about addUserAgentRequestHeader()...?

(I was too hasty to note it was also protected. Sorry!
  Just use Andrea Sodomacos instructions) 

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message