The "Host:" header is required by HTTP/1.1, and is for differentiating
"between internally-ambiguous URLs, such as the root "/"
   URL of a server for multiple host names on a single IP address,"
according to RFC 2616.

I agree that 2 new-lines should suffice. In fact, if I understand section
4.1 of the RFC,  a CRLF is forbidden.

-- Michael





"Steve Mann" <[EMAIL PROTECTED]>@news.palmos.com on 06/08/2001 10:51:15 AM

Please respond to "Palm Developer Forum" <[EMAIL PROTECTED]>

Sent by:  [EMAIL PROTECTED]


To:   "Palm Developer Forum" <[EMAIL PROTECTED]>
cc:

Subject:  Re: Problems sending an HTTP header to a Web Server


>But when I send the same to a Web server,
>after sending the data (GET /prueba.html HTTP/1.0\r\n\r\n) when I am
trying
>to receive something the sockets is closed and I get nothing.

I find that I only need newline, not return characters:

GET /prueba.html HTTP/1.0\n\n

I've also found that some servers want a "Host:" header (I don't
think this is an HTTP convention), even though you're connected to a
specific host via the socket open:

GET /prueba.html HTTP/1.0\nHost:www.hostname.com\n\n

Regards,
Steve Mann
--
-------------------------------------------
Creative Digital Publishing Inc.
1315 Palm Street, San Luis Obispo, CA 93401-3117
-------------------------------------------
805.784.9461              805.784.9462 (fax)
[EMAIL PROTECTED]       http://www.cdpubs.com

--
For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/tech/support/forums/






-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to