Now this is getting weird as I implemented my first agent for this in PHP as 
well (queue Twilight Zone music here)....

Curl is a command line tool and library for getting data from network systems 
(HTTP, TELNET, FTP, GOPHER, etc).  http://curl.haxx.se/  it's quite handy to 
have for quick scripts although Rebol makes it somewhat unneeded for me 
now ;-)

Anyway, here's the code (just a test case):

REBOL []

data: read http://weather.yahoo.com/search/weather2?p=75056

results: []
parse/all data [
    thru {TEXT FORECAST-->}
    any [
        thru <b> copy field to </b> (append results field append results 
newline)
        thru </b> copy field to <p> (append results field append results 
newline)
    ]
    to {<!--ENDTEXT}
]

print results


Hope that helps!

On Thursday 04 March 2004 11:27 am, Carlos Lorenz wrote:
> Hi Greg
>
> I would appreciate to study your code if you don't mind
>
> I have one to scan Yahoo Weather - not completed tested, but written in PHP
> if you want I may send you
>
> Sorry for my ignorance but what's curl anyway?
>
> CArlos
>
> Em Quinta 04 Mar�o 2004 14:10, you wrote:
> > I'm doing the same thing but getting my info from weather.yahoo.com.  I
> > can send you the code if you like.  Also, if you want to use your code
> > grab curl and run it like this:  curl -D head
> > http://br.weather.com/weather/tenday/BRXX2888
> >
> > You can then view the 'head' file to see what is in the http headers.
> >
> > At least that's how I trouble shoot these things...
> >
> > Greg B.
> >
> > On Thursday 04 March 2004 11:06 am, Carlos Lorenz wrote:
> > > Hi list,
> > >
> > > I used to parse some info from weather channel home site
> > > with a small script using REBOL.
> > >
> > > Last week the script just stopped working and while trying to
> > > investigate the reasons to the situation I have discovered that the
> > > following command
> > >
> > > "read http://br.weather.com/weather/tenday/BRXX2888 "  does not work
> > > anymore as expected.
> > >
> > > Now It seems my script is beeing redirected to another page by the guys
> > > at Weather.Com.
> > >
> > > My question is: is there a way to ask REBOL to present himself as a
> > > webbrowser to a certain host? I ask you this because the url above
> > > (http://br.weather.com/weather/tenday/BRXX2888) still works with the
> > > browser
> > >
> > > TIA
> > >
> > > Carlos Lorenz

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to