# Re: HTTP IO?

**URL:** <https://www.ruby-forum.com/t/re-http-io/102498>\
**Category:** Ruby\
**Created:** [November 16, 2005, 7:31am UTC](https://www.ruby-forum.com/t/re-http-io/102498 "2005-11-16T07:31:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![daniels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3ab097/32.png) [@daniels](https://www.ruby-forum.com/u/daniels)\
**Post date:** [November 16, 2005, 7:31am UTC](https://www.ruby-forum.com/t/re-http-io/102498/1 "2005-11-16T07:31:19Z")

</div>

Well, I’d advise reading

[http://redhanded.hobix.com/inspect/theStoryOfStreamingHttpThroughMouseho](http://redhanded.hobix.com/inspect/theStoryOfStreamingHttpThroughMouseho)  
leWithSubsequentAdventuresInContinuationsAndDuckTyping.html

And using the code there for the HTTPIO object. It’s what works for  
mousehole, which I’ve been using quite happily as my internet proxy, so  
I guess that the HTTPIO object works.

Now the question is, what are you actually doing. Then we can probably  
figure out what’s wrong. Now, \_why’s code doesn’t make an actual IO  
object - just one that looks sufficiently like an IO object for the  
Webrick to be convinced to use the read method - he’s got a specific  
use-case, and crammed the object to work in that situation. It probably  
wont work in yours without further tweaking.

> but stop at before reading the body of the page so I can read
> 
> Horacio

#####################################################################################  
This email has been scanned by MailMarshal, an email content filter.  
#####################################################################################

---

<div class="post-metadata">

**Author:** ![daniels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3ab097/32.png) [@daniels](https://www.ruby-forum.com/u/daniels)\
**Post date:** [November 16, 2005, 7:55am UTC](https://www.ruby-forum.com/t/re-http-io/102498/2 "2005-11-16T07:55:30Z")

</div>

Does a verbatim copy of this code work?? I really don’t understand what  
it  
does but that code gives me syntax errors

316: syntax error def read len = nil; … end

Horacio

Wednesday 16 November 2005 15:30ã?Daniel S. ã?ã??ã¯æ?¸ãã¾ã?ã?:

---

<div class="post-metadata">

**Author:** ![daniels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3ab097/32.png) [@daniels](https://www.ruby-forum.com/u/daniels)\
**Post date:** [November 16, 2005, 7:55am UTC](https://www.ruby-forum.com/t/re-http-io/102498/3 "2005-11-16T07:55:30Z")

</div>

Sorry, also an usage example would be appreciated…

regards,  
Horacio

Wednesday 16 November 2005 15:52ã?Horacio S. ã?ã??ã¯æ?¸ãã¾ã?ã?:
