Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Troubles in CGI land

From: agem:crosswinds at: 27-Apr-2001 4:24

>>>>>>>>>>>>>>>>>> Ursprüngliche Nachricht <<<<<<<<<<<<<<<<<<
Am 25.04.01, 08:40:09, schrieb steve jenson <[stevej--sieve--net]> zum Thema [REBOL] Troubles in CGI land:
> Hi fellow REBOL nerds, > I downloaded the newest REBOL/View yesterday and have been playing
around
> with it again but I'm having a problem with a simple CGI script. > Inside of my cgi-bin, I have a script called test.r, which is the > following: > -------------------------------------- > #!/usr/local/rebol/rebol -cs > print "Content-Type: text/plain" > print "" ; > print "Hello!" > send [stevej--sieve--net] decode-cgi input > --------------------------------------- > The permissions are 755 (rwxr-xr-x), other cgi's run out of this
directory
> just fine, and I'm able to use rebol from the command-line with no
problem,
> with the rebol executable referenced above. > Unfortunately, when I call this CGI from a webbrowser, it starts a
download
> (I assume because of a lack of a Content-Type header) of the following > text: > {** Near: size: size-text self > all [ > para para/origin size: size + para/origin > para/margin size: size + para/margin > ] > ... (funky escape characters) > (you can see this for yourself at http://sieve.net/cgi-bin/test.r) > What is this? When I run that single line from within the REBOL/View > environment, it works fine. I'm baffled. There's nothing in my apache > error logs, and no obvious sign of problems. I'm too new to the
langauge
> to really diagnose it farther so I'd like to call on you kids for > some help.
This is unix-rebol/view needs a running x-server which it can connect to. It tries to setup some stuff vor /view and cannot connect. (you see 'size-text fails, which needs font-information and that) Even if you run on x-windows and start a script on apache, it may fail, since apache may run it as user 'wwwrun or that, which cannot connect to the X startet for yourself. On a server you should choose rebol/core, that works X-less. Volker