[REBOL] how can i... Re:

2000-04-17 Thread icimjs

Hi -= usaps jeronimo =-,

there are two ways your CGI script can receive form input. Through the
input function or through system/options/cgi/query-string.

Which is used depends on whether the form submits its data using GET or
POST. Only when GET is used  the form's data becomes available in
system/options/cgi/query-string. If PUT is used you must use input.

Which request method was used can be determined by retrieving the value of
system/options/cgi/request-method.

There is a function available on www.rebol.org user contributed scripts
that automates that automates the process.


At 05:37 PM 4/17/00 +0200, you wrote:

hi! everybody... i'm really new in this stuff.

i'm trying to make rebol work with html forms, an the thing is:

** Script Error: decode-cgi expected args argument of type: any-string. **
Where: cgi: make object!
decode-cgi system/options/cgi/query-string

i cannot go futher, from this error...

if i ask the value for:
system/options/cgi/query-string

is equal to none (but i don't know what value i need)


can somebody help me!

thank in advance.

--

-= usaps jeronimo =-







;- Elan  [: - )]




[REBOL] how can i... Re:

2000-04-17 Thread allenk


On some servers Rebol returns an empty string if there is nothing in the
query-string, however on
MS based server it returns 'none. So it is a good idea to test the
query-string before decoding.

Some people slip the following line in before decoding prso that it behaves
the same across diferent servers.
if none? system/options/cgi/query-string [system/options/cgi/query-string:
copy ""]


But there isn't much point in decoding an empty query-string anyway...

There are some good cgi examples in the www.rebol.com Howto and in the User
and Libary areas,
as well as on www.rebol.org.

Cheers,

Allen K



- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, April 18, 2000 1:37 AM
Subject: [REBOL] how can i...



 hi! everybody... i'm really new in this stuff.

 i'm trying to make rebol work with html forms, an the thing is:

 ** Script Error: decode-cgi expected args argument of type: any-string. **
 Where: cgi: make object!
 decode-cgi system/options/cgi/query-string

 i cannot go futher, from this error...

 if i ask the value for:
 system/options/cgi/query-string

 is equal to none (but i don't know what value i need)


 can somebody help me!

 thank in advance.

 --

 -= usaps jeronimo =-