> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, January 09, 2002 10:35 PM
> To: [EMAIL PROTECTED]
> Subject: Re: HTTPClient - setting default request headers impl Q
>
>
> On Tue, 08 January 2002, "Craig R. McClanahan" wrote:
>
> > On 8 Jan 2002 [EMAIL PROTECTED] wrote:
> >
> > > Date: 8 Jan 2002 07:41:12 -0800
> > > From: [EMAIL PROTECTED]
> > >
> > > What should happen if one calls setRequestHeader("foo",
> "bar"), and
> > > "foo" is already set to some value as the default header,
> and also, what
> > > should happen if things are the other way around?
> > >
> > > I think that setting a default header should take precedence, no?
> > >
> >
> > In the servlet API, calling response.setHeader("foo",
> "bar") replaces any
> > previous "foo" values, while calling
> response.addHeader("foo", "bar") adds
> > an additional value. You might want to think about using
> that convention.
>
> Yes, I thought about it and I just checked the Servlet API.
> But what if one tries this with HTTP Client:
> meth.setRequestHeader("User-Agent", "FOO");
> and
> meth.setRequestHeader("User-Agent", "BAR");
>
> What should be the final User-Agent request header?
> There can't/shouldn't be User-Agent headers, right?
>
I think User-Agent headers should be allowed. The default should be some
HttpClient identifier. But users should be able to set their own
(overriding) User-Agent header. This would be useful for testing URL's that
take different actions based on User-Agent.
-Doug
> Thanks,
> Otis
>
> _________________________________________________________________
> iVillage.com: Solutions for Your Life
> Check out the most exciting women's community on the Web
> http://www.ivillage.com
>
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
>