Konrad Meyer wrote:
> Quoth Ehud Rosenberg:
>> Anyone knows what is the correct way to do this?
>>
>> Thanks!
>> Ehud
>
> What you need to do is create a Mechanize::URI object (or something like
> that)
> from the string "http://www.mininova.org", and call #get() with that.
>
> HTH,
Hi Konrad,
Thanks for the quick reply

I managed to get around that error by doing the following:
ref = WWW::Mechanize::Page.new(URI.parse("http://www.mininova.org"),
{'content-type'=>'text/html'})
doc = agent.get(url_to_get, ref)
Problem is, when I sniff the package it seems that the referring url is
ignored and it is still set to localhost:3000. I've also tried
specifying a nil page (as I've seen in the mechanize get code itself)
but to no avail...
Any would be appreciated.
BTW - removing the referrer altogether would also work for, albeit it's
a less preferred option.
Thanks!
--
Posted via
http://www.ruby-forum.com/.