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

[REBOL] Re: Apache Config for CGI with REBOL

From: ryanc::iesco-dms::com at: 27-Feb-2001 10:18

As far as I know, all that mime stuff does is tell the browser how it should view your document. It has been a long while since I have set up CGI on Apache, but I still might be able to help. First in srm.conf, check for either or both of these lines... ScriptAlias /cgi-bin /home/httpd/cgi-bin/ AddHandler cgi-script .cgi AddHandler is for executing any file with a certain extension. ScriptAlias is for having a directory that everything in it is assumed executable. Most people use one or the other. Then in your main access.conf make sure there is cgi access in the directories that you will be using cgi. This can be done with "options ExecCGI", like so... <directory /home/httpd/cgi-bin> AllowOveride none options ExecCGI </directory> Then make sure that you cgi files have executable permissions using chmod. And last but not least, make sure that the first line of your cgi file points to rebol. That should be it, --Ryan Raimund Dold wrote:
> Hi, > > I am trying to set up apache on my computer (SuSE 7.1) at home to play with > CGI and REBOL. But it still does not work. I did the following: > > - /etc/mime.types > > added the following line > > application/x-http-rebol r > > - /etc/httpd/httpd.conf > > added the following line > > Addtype application/x-http-rebol .r > > Additionally I created the following simple web page > > ---------------------------------------------------------- > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> > <html> > <head> > <title>REBOL CGI Test</title> > </head> > > <body> > <h1>REBOL CGI Test</h1> > > <a href="cgi-bin/simple-cgi.r"> Mein erster REBOL-CGI Versuch </a> > > <hr> > <address><a href="mailto:[raimund--linux--local]">Raimund Dold</a></address> > <!-- Created: Sat Feb 24 22:13:26 MET 2001 --> > <!-- hhmts start --> > Last modified: Sat Feb 24 22:46:14 MET 2001 > <!-- hhmts end --> > </body> > </html> > ------------------------------------------------------------- > > The script simple-cgi.r looks like the following. > > -------------------------------- > #!/bin/rebol --cgi > REBOL [ ] > > print "Content-Type: text/plain^/" > > print "Hello" > -------------------------------- > > But the browser I tried do not process the page like I expected. Netscape > just shows the script as plain text and konqueror calls rebol and processes > the script as separate process (probably due to the fact that .r files are > mime types in KDE, too) > > Did I miss anything? > > Thanx > > Raimund > > -- > To unsubscribe from this list, please send an email to > [rebol-request--rebol--com] with "unsubscribe" in the > subject, without the quotes.
-- Ryan Cole Programmer Analyst 707-468-5400 I am enough of an artist to draw freely upon my imagination. Imagination is more important than knowledge. Knowledge is limited. Imagination encircles the world. -Einstein