[REBOL] Re: Problem with load/header and trim/lines

2004-03-04 Thread Anton Rolls
What are you trying to do? My suggestion: don't use trim/lines (or read for that matter). The newline between shebang line and the beginning of the rebol header is removed by trim/lines. I think the rebol header must begin on a new line. >> probe load/header {# rebol []} ** Syntax Error: Script

[REBOL] Re: Flash Central

2004-03-04 Thread Jason Cunliffe
> Just as Rebol is being put into the web browser Macromedia Flash is moving > outside of it... > > http://news.com.com/2100-1012-5167812.html?tag=nl hmm... Well actually Flash has been moving onto the desktop for long time now. But Macromedia's own 'Central' application is very poorly conceived

[REBOL] Re: /core async example

2004-03-04 Thread Will Arp
Romano, Gabriele and Ammon, thank you for the feedback! I've done 2 variations of the original and put some comments. You can find them here: http://reboot.ch/space/get-fast Will -- To unsubscribe from this list, just send an email to [EMAIL PROTECTED] with unsubscribe as the subject.

[REBOL] Re: async interface

2004-03-04 Thread Anton Rolls
The advantage of that over a single function, I suppose, is so that you can derive from a standard base object (or choose from several easy-to-use example objects), with the four functions [connect read write close] inside. I would be happy with that, if that was what you were thinking. Also, I

[REBOL] Flash Central

2004-03-04 Thread Karl Robillard
Just as Rebol is being put into the web browser Macromedia Flash is moving outside of it... http://news.com.com/2100-1012-5167812.html?tag=nl -Karl -- To unsubscribe from this list, just send an email to [EMAIL PROTECTED] with unsubscribe as the subject.

[REBOL] testing async://

2004-03-04 Thread Will Arp
>> do http://www.rebol.it/giesse/async-protocol.r connecting to: www.rebol.it Script: "async:// protocol (Asynchronous TCP)" (14-Feb-2004) async protocol loaded >> ? system/ports/wait-list SYSTEM/PORTS/WAIT-LIST is a block of value: [] >> open async://apple.com:80 >> ? system/ports/wait-list

[REBOL] Re: Mac OSX /View problem - solved.

2004-03-04 Thread Maxim Olivier-Adlhoch
Hi Trevor, Does this mean that I can really go ahead and buy myself a used titanium laptop? really, does it work well, or is it clunky and painfull? Do you know of a place where we can view all the limitations (if any) of running rebol/view on OSX with the OS9 emulator? TIA! -MAx --- "You

[REBOL] Problem with load/header and trim/lines

2004-03-04 Thread Hallvard Ystad
Hello list I'm trying to use load/header for a rebol script to retrieve the header. This works fine: >> probe first load/header read http://www.oops-as.no/roy/rebol-scripts/url-handler.r But then trim/lines seems to destroy everything: >> probe first load/header trim/lines read >> http://www.o

[REBOL] Mac OSX /View problem - solved.

2004-03-04 Thread Trevor Gosbell
As usual, I've stumbled across the solution to the "View won't run on Mac OSX" problem completely by accident - enable Open Transport and Shared Library extensions. For what it's worth, here's how to do it: Open System Preferences - Classic - Advanced Under Startup options select "Open Extensi

[REBOL] Re: /core async example

2004-03-04 Thread Romano Paolo Tenca
Hi, Will I should write it in the following mode. Some notes: 1) you can set the awake function using make port! port: make port! [scheme: 'async host: hst port-id: 80 awake: :handl] you cannot use the words 'host or 'handler because the block is bound to the port before execution (like

[REBOL] Re: Help with HTTP protocol

2004-03-04 Thread SunandaDH
Carlos: > 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/BRXX

[REBOL] Re: Help with HTTP protocol

2004-03-04 Thread Greg Brondo
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 scrip

[REBOL] Re: Help with HTTP protocol

2004-03-04 Thread Joel Neely
Hi, Carlos, Carlos Lorenz wrote: > > "read http://br.weather.com/weather/tenday/BRXX2888 " does not work anymore > as expected. > What does it do? At first glance (using NS7.1) that the returned page is making heavy use of JavaScript to manage content. If that's correct (whether through s

[REBOL] async:// Close connection

2004-03-04 Thread Terry Brownell
When I use the following example from the tutorial, my server stop whenever a client disconnects with this message... async protocol loaded Got connection. Peer closed connection. >> rebol [] do %async-protocol.r either error? try [listen: open/no-wait tcp://:3000] [ port: open async:

[REBOL] Re: Help with HTTP protocol

2004-03-04 Thread Carlos Lorenz
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 bu

[REBOL] Re: /core async example

2004-03-04 Thread Gabriele Santilli
Hi Will, On Thursday, March 4, 2004, 5:27:04 PM, you wrote: WA> Must have something to do with: WA> clear system/ports/wait-list WA> but than I would appreciate Gabriele or Marteen opinion on WA> why that should not be done, and what is the right way to WA> do it. When you close the port,

[REBOL] Re: Help with HTTP protocol

2004-03-04 Thread Greg Brondo
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 htt

[REBOL] Help with HTTP protocol

2004-03-04 Thread Carlos Lorenz
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/BRXX2

[REBOL] Re: /core async example

2004-03-04 Thread Ammon Johnson
Oh, and then you have to start with a clean console session cause it gives you this error if you try to run it again... >> loop 10 [get-fast urls] ** User Error: Internal error: recursive call to on-data: should not happen! ** Near: make error! {Internal error: recursive call to on-data: should n

[REBOL] Re: /core async example

2004-03-04 Thread Will Arp
yeap, I did get those errors, but rarely. Must have something to do with: clear system/ports/wait-list but than I would appreciate Gabriele or Marteen opinion on why that should not be done, and what is the right way to do it. Thanks, Will On 4 mar 2004, at 16:42, Ammon Johnson wrote: > > Fro

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Gabriele Santilli
Hi Maarten, On Thursday, March 4, 2004, 12:44:17 PM, you wrote: MK> Yes, but you need to do that once, that will trigger the 'write vent MK> that can take over. Typically I insert the first few chars of an out buffer. It is also possible to insert a big string all at a time (after read or

[REBOL] Re: /core async example

2004-03-04 Thread Ammon Johnson
>From REBOL/Command 2.5.6.3.1 console... >> loop 10 [get-fast urls] www.microsoft.com www.microsoft.com www.microsoft.com www.microsoft.com www.rebol.net ** Access Error: Port none not open ** Where: get-fast ** Near: res: res or async/awake async >From REBOL/Link 1.0.5.3.1 console... >> loop 1

[REBOL] async interface

2004-03-04 Thread Romano Paolo Tenca
I should like to define a common (standard) interface for async protocols. I proposed some time ago an object! style, like the View feel, instead of the awake function. What do you think? --- Ciao Romano -- To unsubscribe from this list, just send an email to [EMAIL PROTECTED] with unsubscrib

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Maarten Koopmans
Hi Christophe, >I do not have very much experience when coming to network protocol, so please excuse >the triviality of my question :). >The fact is I could for sure use this 'async protocol for a project we are now >developing. > > Good. >I tried the following, but without any result. I try

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Will Arp
I think you need a slash before "logo.jpg" and a space after "Host:" -> insert port {GET /logo.jpg HTTP/1.0^M^JHost: 127.0.0.1^M^J^M^J} On 4 mar 2004, at 15:11, Coussement Christophe wrote: > insert port {GET logo.jpg HTTP/1.0^M^JHost:127.0.0.1^M^J^M^J} Will -- To unsubscribe from this list,

[REBOL] /core async example

2004-03-04 Thread Will Arp
;copy-paste this in console and you'll see who is faster! ;thanks to Gabriele, Marteen, Romano and Carl 8) do http://www.rebol.it/giesse/async-protocol.r get-fast: func [hosts /local port][ foreach host hosts [ uri: host port: open rejoin [async:// host "

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Coussement Christophe
Hi Maarten, I do not have very much experience when coming to network protocol, so please excuse the triviality of my question :). The fact is I could for sure use this 'async protocol for a project we are now developing. I tried the following, but without any result. I try to load a %dghr.jpg

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Maarten Koopmans
Terry Brownell wrote: >ok, in answer to my own question, you can use "insert port" at anytime >while processing script. > >TB > >Terry Brownell wrote: > > > Yes, but you need to do that once, that will trigger the 'write vent that can take over. Typically I insert the first few chars of an ou

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Maarten Koopmans
Terry Brownell wrote: >Using the server example in the doc, the server stops once the client >disconnects? > >Terry > > No, it closes the connection with this particular client only. --Maarten -- To unsubscribe from this list, just send an email to [EMAIL PROTECTED] with unsubscribe as the s

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Terry Brownell
ok, in answer to my own question, you can use "insert port" at anytime while processing script. TB Terry Brownell wrote: >I was misunderstood.. what I meant was, once I get some stuff FROM read.. and >do some magic with it (ie: get the result of 2 + 2).. how do I send the RESULT >back to the

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Terry Brownell
Using the server example in the doc, the server stops once the client disconnects? Terry -- To unsubscribe from this list, just send an email to [EMAIL PROTECTED] with unsubscribe as the subject.

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Terry Brownell
I was misunderstood.. what I meant was, once I get some stuff FROM read.. and do some magic with it (ie: get the result of 2 + 2).. how do I send the RESULT back to the client via WRITE? I dont have a problem with getting or processing READ. Terry Terry Brownell wrote: >Excellent.. finally s

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Maarten Koopmans
add a false after the read code :-) Terry Brownell wrote: >Excellent.. finally some light in this dark hole of tcp. > >I have a couple of questions though.. in the handler we have connect, >read, write close.. how can i do this... > >connect [] >read [ (read the buffer, which in this case is "

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Maarten Koopmans
Terry Brownell wrote: >Excellent.. finally some light in this dark hole of tcp. > >I have a couple of questions though.. in the handler we have connect, >read, write close.. how can i do this... > >connect [] >read [ (read the buffer, which in this case is "2 + 2", and having >processed this t

[REBOL] Re: The REBOL async:// tutorial - take 1

2004-03-04 Thread Terry Brownell
Excellent.. finally some light in this dark hole of tcp. I have a couple of questions though.. in the handler we have connect, read, write close.. how can i do this... connect [] read [ (read the buffer, which in this case is "2 + 2", and having processed this to a result string of "4"...)] w