I dont know how you could do that from a browser. But lets say i want to send a HEAD request for the resource at http://localhost:8080/index.jsp I would do the following: (actually tried it..it works) 1. Goto DOS prompt >telnet localhost 8080 HEAD /index.jsp HTTP/1.0 Host: localhost
[dont forget to hit enter twice] I get the following reply: HTTP/1.1 200 OK Set-Cookie: JSESSIONID=A540757E5EFAFD11D54ADF0C44D56F16; Path=/ Content-Type: text/html;charset=ISO-8859-1 Transfer-Encoding: chunked Date: Tue, 29 Jul 2003 11:38:45 GMT Server: Apache Coyote/1.0 Connection to host lost. Press any key to continue...
Hi, also, if you have the Core Servlets and JSP book, you can use the sample WebClient to simulate a client browser through which you can send any http header, like the HEAD one you want. This book and its examples are also free for downloading at http://www.coreservlets.com/. Of course, you can code you own program to conect to a webserver (port 80 or 8080) and send the corresponding headers. Dani
Joined: Feb 04, 2003
Thank You very much! It is functionable and veri usefull for studying scope. Still thanks, Veri!