# Request.raw\_post into Tempfile

**URL:** <https://www.ruby-forum.com/t/request-raw-post-into-tempfile/168940>\
**Category:** Rails\
**Created:** [May 27, 2009, 4:22pm UTC](https://www.ruby-forum.com/t/request-raw-post-into-tempfile/168940 "2009-05-27T16:22:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mokkai](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/c2a13f/32.png) [@mokkai](https://www.ruby-forum.com/u/mokkai)\
**Post date:** [May 27, 2009, 4:22pm UTC](https://www.ruby-forum.com/t/request-raw-post-into-tempfile/168940/1 "2009-05-27T16:22:07Z")

</div>

i have flash application ,which will give a jpg file as raw\_post

from that raw\_post i am trying to store into a tempfile

tempfile=Tempfile.new(“myfile.jpg”)  
tempfile.write(request.raw\_post)

but always “tempfile.read” giving “”(not storing the data) as output

i don’t why ?

any help ?
