Re: Accessing POST Data More Than Once

Brian Candler <[email protected]> Mon, 14 Nov 2005 22:38:27 +0000
Newsgroups gmane.comp.apache.mod-ruby
Message-ID <[email protected]>
On Mon, Nov 14, 2005 at 01:36:39PM -0600, Ben Gribaudo wrote:
> Hi,
> 
> How do I access POSTed data more than one time from a script?
> 
> If you submit data using the example below, the first 
> Apache.request.read returns the POSTed data while subsequent calls 
> return nil instead of repeating the POSTed data.
> 
> Thank you,
> Ben Gribaudo
> 
> <pre>
> <%
> puts Apache.request.read # expected data
> puts Apache.request.read # nil
> puts Apache.request.read # nil
> %>

foo = Apache.request.read
puts foo
puts foo
puts foo

?