Mailing List ArchiveSupport open source code!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]tlug: HTTP headers q
- To: tlug@example.com
- Subject: tlug: HTTP headers q
- From: "Stephen J. Turnbull" <turnbull@example.com>
- Date: Thu, 17 Feb 2000 14:06:37 +0900 (JST)
- Content-Transfer-Encoding: 7bit
- Content-Type: text/plain; charset=us-ascii
- In-Reply-To: <20000217133805.A15316@example.com>
- References: <20000217133805.A15316@example.com>
- Reply-To: tlug@example.com
- Sender: owner-tlug@example.com
>>>>> "FB" == =?iso-2022-jp?B?GyRCJVUlaSVzJS8kWSVNJUMlSBsoQg==?= <bennett@example.com> writes: FB> I am having trouble with HTTP headers again. Yes. Read RFC-822 (just for fun and a BNF review) and RFC-2045. Wouldn't hurt to read RFC-204[6789], too, but that's asking a lot and not directly relevant. ;-) FB> if {[lsearch -exact [cgi_cookie_list] clientid]==-1} { FB> puts "Content-type: content=\"text/html\"; charset=\"EUC-JP\"" Just puts "Content-Type: text/html; charset=EUC-JP" should do nicely. The "content =" stuff is a <META HTTP-EQUIV=...>-ism. RFC-2045 headers don't have that. The (escaped) quotes are unnecessary since none of the value parts have syntactic roles. FB> puts "Pragma: content=\"no-cache\"" Probably ditto, but I don't grok Pragma headers. Very implementation dependent in general although "no-cache" is a standard one IIRC. FB> puts "Set-Cookie: clientid=$clientid" } FB> When I "fixed" things so that Content-type: and the Pragma: FB> both output always, and added the empty line, I got what looks FB> like *Apache's* Content-type: header (text/plain) as part of FB> the text of the document when it is rendered. What's Apache FB> putting its finger into the works for? Evidently Apache or FastCGI tries to be helpful by adding a default header if it doesn't detect a valid one. It's interesting that Lynx doesn't worry about it. FB> If anyone has read this far without their eyes glazing over FB> ... any suggestions? Including (especially) texts I should FB> read to better learn my way around Apache and CGI programming. Just remember that an HTTP document is actually an RFC-2045 message for all practical purposes and you should be OK. Also, there are several Perl libraries and a standard Python library for CGIs. I don't know which are standard for Perl, but you should consider using those, as a lot of this gook will be replaced by setting variables. -- University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN Institute of Policy and Planning Sciences Tel/fax: +81 (298) 53-5091 _________________ _________________ _________________ _________________ What are those straight lines for? "XEmacs rules." -------------------------------------------------------------------- Next Nomikai Meeting: February 18 (Fri) 19:00 Tengu TokyoEkiMae Next Technical Meeting: March 11 (Sat) 13:00 Temple University Japan * Topic: TBD -------------------------------------------------------------------- more info: http://www.tlug.gr.jp Sponsor: Global Online Japan
- Follow-Ups:
- Re: tlug: HTTP headers q
- From: Fredric Fredricson <fredric.fredriksson@example.com>
- References:
- tlug: HTTP headers q
- From: "Frank Bennett (=?iso-2022-jp?B?GyRCJVUlaSVzJS8kWSVNJUMlSBsoQg==?= )" <bennett@example.com>
Home | Main Index | Thread Index
- Prev by Date: tlug: wc for Japanese / fetchmail
- Next by Date: Re: tlug: 2/18 Nomikai Attendance
- Prev by thread: tlug: HTTP headers q
- Next by thread: Re: tlug: HTTP headers q
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links