httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lee <lee...@gmail.com>
Subject Re: [users@httpd] How htaccess enables CGI script as default page
Date Thu, 03 Mar 2011 08:05:46 GMT
Sometimes you refer to the Perl scripts with absolute paths, sometimes 
relative. I do no know what dir your .htaccess is in, but please check 
the paths.

It also seems that you changed the .htaccess references to .pl extension 
to .py -- was there a reason for that?

Sorry I missed the start of this - there is too little history in the 
post to catch up properly.

Please post again, with log file snippets, if you are still having problems.

Lee

On 03/03/2011 08:38, Manoj Samtani wrote:
> What error you are getting or in log file?? And did you changed 
> index.py permissions to 755 ??
>
> Thanks,
> Manoj
>
> > Date: Wed, 2 Mar 2011 15:11:25 -0900
> > From: tim@johnsons-web.com
> > To: users@httpd.apache.org
> > Subject: Re: [users@httpd] How htaccess enables CGI script as 
> default page
> >
> > * David Christensen <dpchrist@holgerdanske.com> [110302 15:01]:
> > > On 03/02/2011 03:22 PM, Tim Johnson wrote:
> > > >I'm attempting to use .htaccess to make an executable python script
> > > >as the default page for a directory.
> > >
> > > I recently wanted to have *all* hits for a particular subtree to go
> > > to a Perl CGI script on Debian 6.0.0 and Apache 2.2 via .htaccess.
> > > The key was realizing that I could catch index hits via
> > > DirectoryIndex and "not found" hits via ErrorDocument 404.
> > >
> > >
> > > I ended up with two files in my DocumentRoot:
> > >
> > > .htaccess
> > > handler.pl
> > >
> > >
> > > Here is .htaccess:
> > >
> > > $ cat .htaccess
> > > Options +ExecCGI
> > > AddHandler cgi-script pl
> > > DirectoryIndex handler.pl
> > > ErrorDocument 404 /errordocument/handler.pl
> > Hi David:
> > Using your example I changed my .htaccess so that
> > it has the following (only):
> > ##
> > Options +ExecCGI
> > AddHandler cgi-script py
> > DirectoryIndex index.py
> > ##
> > .htaccess is chmod 644
> > Same results as before..
> > thanks for the reply
> >
> > obviously still something wrong on my end.
> > --
> > Tim
> > tim at johnsons-web.com or akwebsoft.com
> > http://www.akwebsoft.com
> >
> > ---------------------------------------------------------------------
> > The official User-To-User support forum of the Apache HTTP Server 
> Project.
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> > " from the digest: users-digest-unsubscribe@httpd.apache.org
> > For additional commands, e-mail: users-help@httpd.apache.org
> >

Mime
View raw message