> >>> "Mac Donell, Marc" <[EMAIL PROTECTED]> 16-Jun-00 9:40:59 PM >>>
>> Also is there a way to easily determine that said header has been
>> added? Is the doPost() function the proper place for this?
Nic Ferrier writes:
> Use a packet sniffer to view the output of the response.
>
> Or you could telnet to the container and issue the request by hand,
> eg: if you host is called bob, tour servelt is mapped to: /myservlet
> and the container is on port 8080:
>
> telnet bob 8080
> GET /myservlet HTTP/1.0
> [press return]
> [press return]
>
> you will then see the container response.
Both good ideas; I strongly recommend anybody playing with
servlets to get the HTTP spec (or maybe Clint Wong's _Programming Web
Clients_, from O'Reilly, even if it does use Perl for the example code
:-), sit down and play with the server at a telnet prompt. Actually I
tend to use emacs, shell out and run telnet from there, so I can use
the buffer editing commands.
Another thing I strongly recommend is getting and installing some
simple proxy server on your machine, and using it to watch your
browser and server talk to each other. If you're using Linux you have
a lot of fine alternatives, but for a windows box, I found a program
called HttpProxySpy to be quite handy, last year. It was designed
specifically to make it easy to watch the action, so it displayed each
message as a single line and expanded it to show the whole message
when you clicked on it. It completely changes the experience of doing
web coding. Without a proxy to watch, it's like picking a lock, going
by "feel" alone, a painstaking process.
Steven J. Owens
[EMAIL PROTECTED]
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html