Index: [Article Count Order] [Thread]

Date:  15 Feb 2002 08:59:09 -0600
From:  Dave Thomas <Dave@PragmaticProgrammer.com>
Subject:  [webricken:17] Re: Help with a 408 error
Sender:  dave@thomases.com
To:  webricken@notwork.org
Message-Id:  <m2aduazt8i.fsf@zip.local.thomases.com>
In-Reply-To:  GOTO Kentaro's message of "Fri, 15 Feb 2002 15:53:51 +0900 (JST)"
References:  <m2wuxfz70f.fsf@zip.local.thomases.com> <20020215.155351.77048701.gotoken@notwork.org>
X-Mail-Count: 00017

GOTO Kentaro <gotoken@notwork.org> writes:

> That doesn't be reproduced on my Window ME box with 
> sample/httpd/htdocs/test.rhtml.  Could you show the rhtml or any example?

Here's my webrick httpd:

     require 'webrick'

     #dir = File::dirname(File::expand_path(__FILE__))

     s = WEBrick::HTTPServer.new(
      :Port           => 2000,
      :DocumentRoot   => "./htdocs"
     )

     trap("INT") { s.shutdown }
     s.start


Here's a cutdown .rhtml

     <html><head><title>Your Order</title></head>
     <body>
     <hr>
     <h1>Your Order</h1>
     <form action="test.rhtml">
     <%=
       customer = request.query['customer']

       if !customer
         label = "Lookup"
         'Your name: <input type="text" name="customer">'
       else
         label = "Lookup another"
       end
     %>
     <p>
     <input type="submit" name="find" value="<%=label%>">
     </form>
     <hr></body></html>

And here's the log I get

     C:\work\PP\doc\Talks\SDWest_Ruby\code>ruby httpd1.rb
     [2002-02-15 08:42:02] INFO  Logging start (level=4).
     [2002-02-15 08:42:02] INFO  WEBrick::HTTPServer#start: pid=452 port=2000
     [2002-02-15 08:42:02] INFO  thread(0) start.
     [2002-02-15 08:42:02] INFO  thread(1) start.
     [2002-02-15 08:42:02] INFO  thread(2) start.
     [2002-02-15 08:42:02] INFO  thread(3) start.
     [2002-02-15 08:42:02] INFO  thread(4) start.
     [2002-02-15 08:42:08] INFO  127.0.0.1 "GET /test.rhtml HTTP/1.0" 200 231 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0; Q312461)"
     [2002-02-15 08:42:14] INFO  127.0.0.1 "GET /test.rhtml?customer=aaaa&find=Lookup HTTP/1.0" 200 207 "http://localhost:2000/test.rhtml"; "Mozilla/4.0 (compatible;
     MSIE 6.0; Windows NT 5.0; Q312461)"
     [2002-02-15 08:42:44] INFO  127.0.0.1 "" 408 0 "-" "-"


(No idea why it says Mozilla - it's IE)


Dave