Carlos:
How do I use REBOL to write a CGI script
that builds a page with a download link?
Simply version: you just need a href to the file that you want downloaded.
Take a look at the source of:
http://www.rebol.org/cgi-bin/cgiwrap/rebol/download-librarian.r
The click here to
Though, as noted on an earlier message on this list, doing so means that you
will only get one value from a multi-select input.
Brett.
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 04, 2000 8:08 PM
Subject: [REBOL] CGI Re:
Sharriff Aina
It simply makes an easy-access object out of the data:
decode-cgi "foo=10bar=20"
== [foo: 10 bar: 20]
when you make an object out of it with:
cgi: make object! decode-cgi "foo=10bar=20"
you can access the form values like this:
cgi/foo
== 10
cgi/bar
== 20
The reason you might not make an
Here is what I have discovered.
Printing text/html output of the following...
print {INPUT TYPE="hidden" name="article-reference" value="27155544"}
...passes a URL appended with "?article%2Dreference=27155544" creating a
word REBOL cannot use.
while...
print {INPUT TYPE="hidden"
Well, using...
cgi-input: make object! decode-cgi system/options/cgi/query-string
and then calling "comments-reference" using cgi-input/comments-reference
from the url...
http://www.beosjournal.com/cgi-bin/displaycomments.cgi?comments-reference=
2715121834
Worked! I can now view the
Ryan wrote:
I need to figure out how to pass a static value with a form, one that is
not generated or chosen by the submitter.
IIRC, hidden controls in the HTML form will provide this.
Andrew Martin
ICQ: 26227169
http://members.xoom.com/AndrewMartin/
--
00 3:45 AM
Subject: [REBOL] CGI Re:(2)
Howdy, Daniel:
Thank you for your help, everyone.
This is how far I've got until now :
Apparently, file access is working normally
only in the
first cgi script launchedby Apache, all
itschild
Hello,
You mentioned that the scripts runs another script with 'do/args - where
does that other script reside? Is it in the same/lower directory, or a
higher?
The latter script reside in a higher directory.
Regards,
Rachid
--
[EMAIL PROTECTED]
http://perso.worldonline.fr/mutant
Thank you for your help, everyone.
This is how far I've got until now :
Apparently, file access is working normally only in the first cgi
script launched by Apache, all its child processes (subsequent calls
of scripts, whether they reside in cgi-bin or elsewhere) have problems
to access the
Howdy, Daniel:
Thank you for your help, everyone.
This is how far I've got until now :
Apparently, file access is working normally only in the
first cgi script launchedby Apache, all itschild
processes (subsequent calls of scripts, whether they reside
in
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, June 15, 2000 3:45 AM
Subject: [REBOL] CGI Re:(2)
Howdy, Daniel:
Thank you for your help, everyone.
This is how far I've got until now :
Apparently, file access is working
So, Daniel: what do you see if you do what-dir in the
other script? Can you change-dir? What are the
system/options/path, and system/script/path values?
Can your script write out a test file, if so, where
does it show up?
The exists? function
So, Daniel: what do you see if you do what-dir in the
other script? Can you change-dir? What are the
system/options/path, and system/script/path values?
Can your script write out a test file, if so, where
does it show up?
Jeff,
All the above works as
Thank you for your answer.
I don't see why this would happen, as I'm working on local files with
an administrator account (NT).
What user does the *web server* run as? CGI scripts will inherit the
same permissions as the web server, which usually runs with minimal
permissions.
Regards,
Hello,
You mentioned that the scripts runs another script with 'do/args - where
does that other script reside? Is it in the same/lower directory, or a
higher?
Regards,
Rachid
Try this... you just need to write out and read in as binary to get
the file read and sent properly.
Sterling
#!/usr/local/bin/rebol -csq
REBOL []
file: read/binary %test.xls ; file is 17920 bytes long
prin [
{Content-Type: application/octet-stream; name="file"} newline
I am no expert either, but I seem to have it going (at last).
I added the following to access.conf
Directory /home/ingo/public_html
AllowOverride All
Options ExecCGI FollowSymLinks
order allow,deny
allow from all
/Directory
This allows me to use CGI (ExecCGI) within the dir
Well ... I have been waiting for a reply to the message below. Has there
been a reply and I missed it? I have been trying to use rebol for CGI
scripts which is the main reason why I started to use it. People have send
CGI examples to me, which work for them but they don't work for me. I have
by
18 matches
Mail list logo