[REBOL] Re: Trouble with running on server
From: SunandaDH:aol at: 24-Jan-2004 17:18
> It is a Linux server running on Dual AMD 2.13 GHz.
> I uploaded Rebol042 and renamed it rebol.
> I've Chmod it for all Read and All Execute. (755)
You also need to Chmod the script you want to run as 755.
> My first line of my script points to the file...I think. I've tried so
> paths but none seem to work. I keep getting "Internal Server Error".
> If I place rebol core in my cgi-bin directory and I run my script from
> directory what should the first line of my script look like?
where /---/ is the path to your cgi-bin folder. Other things to check:
-- do you have a REBOL header?
-- are you outputting a content-type header and a blank line before any HTML?
-- If you are uploading the script from a non-UNIX environment (Win, MAC) has
your upload converted the line endings correctly?
--Is the script free of syntax errors? Try 'DOing it in a REBOL console
before you do)
Try this as a minimalist example:
REBOL  ;; empty REBOL header
print "Content-type: text/html^/" ;; print HTTP header and blank line
print "Allo Le Monde!" ;; print HTML page
quit ;; end with a Quit, not a Halt
If you are planning to do an extensive CGI development, check out some useful
toys in the Library, eg: