[R] CGIwithR

David Firth d.firth at warwick.ac.uk
Sun Jan 16 21:50:20 CET 2005


See below for the reply I sent you when you asked me this earlier today.

David

On 16 Jan 2005, at 20:22, ebashi wrote:

> Dear R users;
> I'm trying to use CGIwithR on a linux machine, I have
> followed the instructions on the package manual but
> still it does not run,
> the message that I get is as follows:
>     The requested URL was not found on this server
> I used the example trivial, I put trivial.html under
> Web directory and trivial.R in cgi-bin directory,
> which itself is a subdirectory of Web directory, ( I
> have changed the modes of R.cgi and .Rprofile
> according to what package says) but i still get
> the same message, do you have any tips for me? my
> question is that where should for example myscript.R
> that is mentioned in the manual, be
> placed? (under Web directory or
> under cgi-bin).
> besides the path to R and GS, should anything else in
> the R.cgi be changed?
>
> many tanx in advance
> Sean
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
>
Dear Sean

Thanks for your email.  It is hard to diagnose your problem at a 
distance, but here is some general stuff:

-- the trivial.html file needs to be in a place that is served by your 
http server (is that the URL that is not found?  ie can you see the 
form in your browser?  it wasn't clear to me from your email.)

-- your web server needs to be configured to allow CGI scripts, and 
probably to specify one or more directories where such scripts are 
allowed to live.  This is often a directory called cgi-bin; but note 
that it is not enough just to create a directory with that name, you 
must tell your webserver through its configuration file(s) that it 
exists and that CGI scripts placed there can be run.  How this is done 
depends on which HTTP server you are running, and I cannot help you 
with that I'm afraid.

-- the trivial.R, R.cgi and .Rprofile files all need to be in one of 
the places where CGI scripts are allowed (by your HTTP server) to live.

I hope that helps.  Good luck.

best wishes,
David




More information about the R-help mailing list