[gambit-list] cgi in Gambit

Marc Feeley feeley at iro.umontreal.ca
Tue Dec 13 14:38:31 EST 2011


On 2011-12-13, at 2:16 PM, Eduardo Costa wrote:

> #! ./gsi-script -:d-
> 
> (display "Content-type: text/html")
> (newline)
> (newline)
> (display 
> "<html>
>   <body>
>    <h1>Hello from Gambit</h1>
>   </body>
> </html>" )
> (newline)
> 
> 
> Here is the message that I get from Hostgator both for the scripting version and the compiled version:
> 

It is very probable that the current-directory that is in effect when the CGI script is executed is **not** the one that contains the gsi-script executable.

Please:

1) figure out where the gsi-script executable is on the **server** machine (for example, /usr/bin/gsi-script)

2) put the complete path of the gsi-script executable in the first line of your script, i.e.

#! /usr/bin/gsi-script -:d-
...

An alternative that might work on the server is to use

#! /usr/bin/env gsi-script -:d-

This assumes that the PATH is properly setup on the server.

Marc




More information about the Gambit-list mailing list