From: OZAWA -Crouton- Sakuro Date: 2000-08-01T15:29:08+09:00 Subject: [ruby-list:24062] Re: mod_ruby/eruby/header さくです。 At Tue, 1 Aug 2000 10:14:34 +0900, Shugo Maeda wrote: > lynx -head -dumpでヘッダを確認してみていただけますでしょうか? なんかヘンです。HTTPヘッダだけじゃなくてその後にHTMLドキュメント本体が付い てきてしまいました。 他のファイルも調べてみたのですが、通常のHTMLファイルだと、ちゃんとヘッダだ けが返されるのに……、rhtmlだとヘッダの後ろの本体まで付いてきちゃってまし た。 crouton@sextant:~$ lynx -head -dump http://www/~crouton/test.rhtml HTTP/1.1 200 OK Date: Tue, 01 Aug 2000 06:17:42 GMT Server: Apache/1.3.12 (Unix) (Kondara MNU/Linux) mod_ruby/0.1.4 Ruby/1.4.4(200 0-03-13) Connection: close Content-Type: text/html; charset=EUC-JP Content-Encoding: 7bit mod_ruby test

mod_ruby test

crouton@sextant:~$ Apacheのmod_ruby関連の設定は、 DirectoryIndex index.html index.htm index.shtml index.cgi index.rhtml index.jhtml LoadModule ruby_module modules/mod_ruby.so AddType application/x-httpd-eruby .rhtml だけです。また、mod_rubyだけで、erubyは入れてません。 -- OZAWA -Crouton- Sakuro E-Mail: mailto:crouton@weatherlight.org mailto:crouton@duelists.org mailto:crouton@isoternet.org mailto:crouton@serika.ne.jp Web: http://www.weatherlight.org/~crouton/ PGP: C98F 74E0 AEEB 4578 1DFC F650 3BE0 9627 11FC C9F5 ちょっといじったので、一応再掲: <%class Time def to_s strftime('%a, %d %b %Y %H:%M:%S %Z') end end require 'cgi' cookie = CGI::Cookie.new('Test', 'HELLO') Apache::request['Set-Cookie'] = cookie.to_s Apache::request['Last-Modified'] = Time.now.gmtime.to_s %> mod_ruby test

mod_ruby test