[PHP] PHP/CGI Help
Hi all, This is a tough one, wasn't able to find a solution so far. But I hope that someone can help me out or point me in the right direction. Here is what I got: /src contains a bunch of cgi scripts that require apache to have an entry like this ScriptAlias /src "/home/src/" When I try to run a file with .php extension in /src I get an error. I figured out since I have ScriptAlias /src, Apache will handle every file called in that directory as if it were a perl /cgi program. I need to be able to have apache execute the .cgi and .php files in /src Any ideas on how to make Apache differentiate between the two. Any help would be greatly appreciated. Nick -- ~ Nicholas Marouf || http://www.RamallahOnline.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PHP/CGI Help
do .php files work anywhere else? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Maroufski Sent: Thursday, March 22, 2001 5:41 PM To: [EMAIL PROTECTED] Subject: [PHP] PHP/CGI Help Hi all, This is a tough one, wasn't able to find a solution so far. But I hope that someone can help me out or point me in the right direction. Here is what I got: /src contains a bunch of cgi scripts that require apache to have an entry like this ScriptAlias /src "/home/src/" When I try to run a file with .php extension in /src I get an error. I figured out since I have ScriptAlias /src, Apache will handle every file called in that directory as if it were a perl /cgi program. I need to be able to have apache execute the .cgi and .php files in /src Any ideas on how to make Apache differentiate between the two. Any help would be greatly appreciated. Nick -- ~ Nicholas Marouf || http://www.RamallahOnline.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PHP/CGI Help
you also need to have ScriptAlias /src "/home/src/" Action application/x-httpd-php4 "php excicution file location" AddType application/x-httpd-php4 .php -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Maroufski Sent: Thursday, March 22, 2001 5:41 PM To: [EMAIL PROTECTED] Subject: [PHP] PHP/CGI Help Hi all, This is a tough one, wasn't able to find a solution so far. But I hope that someone can help me out or point me in the right direction. Here is what I got: /src contains a bunch of cgi scripts that require apache to have an entry like this ScriptAlias /src "/home/src/" When I try to run a file with .php extension in /src I get an error. I figured out since I have ScriptAlias /src, Apache will handle every file called in that directory as if it were a perl /cgi program. I need to be able to have apache execute the .cgi and .php files in /src Any ideas on how to make Apache differentiate between the two. Any help would be greatly appreciated. Nick -- ~ Nicholas Marouf || http://www.RamallahOnline.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PHP/CGI Help
Hi Peter, Thanks for all the help. I actually started playing with what you told me, and then did some trial-and-error testing and found out that I didn't need ScriptAlias /src "/home/src/" at all.The .php3 files ran when I removed it, then I added these two lines to get the .pl and .cgi to work for the virtual host. AddHandler cgi-script .cgi AddHandler cgi-script .pl Works like a charm. Thanks again. Nick Peter Houchin wrote: you also need to have ScriptAlias /src "/home/src/" Action application/x-httpd-php4 "php excicution file location" AddType application/x-httpd-php4 .php -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Maroufski Sent: Thursday, March 22, 2001 5:41 PM To: [EMAIL PROTECTED] Subject: [PHP] PHP/CGI Help Hi all, This is a tough one, wasn't able to find a solution so far. But I hope that someone can help me out or point me in the right direction. Here is what I got: /src contains a bunch of cgi scripts that require apache to have an entry like this ScriptAlias /src "/home/src/" When I try to run a file with .php extension in /src I get an error. I figured out since I have ScriptAlias /src, Apache will handle every file called in that directory as if it were a perl /cgi program. I need to be able to have apache execute the .cgi and .php files in /src Any ideas on how to make Apache differentiate between the two. Any help would be greatly appreciated. Nick -- Nicholas Marouf || System Administrator/Security Response Team http://www.ramallahonline.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]