cgi problems in 1.6.6
Posted by: xeandor (---.brenham.tx.cebridge.net)
Date: November 17, 2006 05:26AM

ok so I downloaded the cgi plugin and installed it. to d:/wamp/perl

I then searched the forums and found one suggestion that I tried and it failed to work...then I found another suggestion to change some of my code in my httpd.conf file and that was to modify my code to look like

<Directory "d:/wamp/www">
AllowOverride All
Options Indexes FollowSymLinks Includes +ExecCGI
Order allow,deny
Allow from all
</Directory>

and also I changed the addhandler line to read this...

AddHandler cgi-script .cgi .pl

and I tried to test it all out by using a simple hello world document:

#!D:/wamp/perl/bin/perl

# hello_s.pl-- simple "hello, world" program to demonstrate basic
# CGI output.
#

# Print the CGI response header, required for all HTML output
# Note the extra \n, to send the blank line
print "Content-type: text/html\n\n" ;

# Print the HTML response page to STDOUT
print <<EOF ;
<html>
<head><title>CGI Results</title></head>
<body>
<h1>Hello, world.</h1>
</body>
</html>
EOF

exit ;

...anyways I stuck the file in several places and tried it...I started with the d:/wamp/apache2/cgi-bin ...no luck, so I tried it in d:/wamp/www

....same, it would output just the html tags with the text inbetween them....

what did I do wrong, and is this a problem specific to 1.6.6, great program otherwise as far as im concerned, pretty simple to install...and hopefully someone can help me with this problem. thanks

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: CyberSpatium (71.237.217.---)
Date: November 17, 2006 01:37PM

dont use a cgi-bin since you added +ExecCGI to the options directive for the d:/wamp/www directory, just store them in the www directory.

try changing:
#!D:/wamp/perl/bin/perl

to
#!D:/wamp/perl/bin/perl.exe

also remember anytime you edit your httpd.conf or php.ini file, you need to restart apache for the new settings to take effect.


CyberSpatium
WAMP English Forum Admin

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: xeandor (---.brenham.tx.cebridge.net)
Date: November 17, 2006 10:39PM

hmm...I restarted apache, and added .exe to the end of the #!D:/wamp/perl/bin/perl and it gave me a

forbidden statment saying that I dont have permission to access /test.cgi on my server...(I tried it both from the localhost and from my webaddress that I obtained) both ways it gave me the same thing. (I did this because I cant seem to access phpmyadmin and the sqllitemanager, except from my localhost adress, how do I change this?)

and I checked my error log for apache and found...

[Fri Nov 17 15:36:55 2006] [notice] Apache/2.0.59 (Win32) PHP/5.2.0 configured -- resuming normal operations
[Fri Nov 17 15:36:55 2006] [notice] Server built: Jul 27 2006 15:55:03
[Fri Nov 17 15:36:55 2006] [notice] Parent: Created child process 4532
[Fri Nov 17 15:36:56 2006] [notice] Child 4532: Child process is running
[Fri Nov 17 15:36:56 2006] [notice] Child 4532: Acquired the start mutex.
[Fri Nov 17 15:36:56 2006] [notice] Child 4532: Starting 250 worker threads.


another thing for some reason in my php error log it keeps recording

[17-Nov-2006 15:36:55] PHP Warning: Zend Optimizer does not support this version of PHP - please upgrade to the latest version of Zend Optimizer in Unknown on line 0


but I already downloaded yalls zend optimizer plugin...and it kept on outputing that, is there extra configuration on that too besides just the installation via the .exe file?

thanks for your help...hopefully I can get this figured out grinning smiley

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: CyberSpatium (71.237.217.---)
Date: November 18, 2006 01:23AM

try changing to:

<Directory "d:/wamp/www">
AllowOverride All
SetHandler cgi-script
Options Indexes FollowSymLinks Includes +ExecCGI
Order allow,deny
Allow from all
</Directory>




CyberSpatium
WAMP English Forum Admin

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: xeandor (---.brenham.tx.cebridge.net)
Date: November 18, 2006 02:05AM

ok changed the code, saved it restarted, and then tried to access the test.cgi file in the root (www) field where I had put it and I got

Forbidden

You don't have permission to access /test.cgi on this server.

...tried both [localhost] (also without the / on the end) and [www.empiredkp.game-host.org] (also with and without the / on the end) same result every time

after I tried to go there I opened my apache log and it said:

[Fri Nov 17 19:06:32 2006] [error] [client 127.0.0.1] Options ExecCGI is off in this directory: D:/wamp/www/test.cgi
[Fri Nov 17 19:09:59 2006] [notice] Apache/2.0.59 (Win32) PHP/5.2.0 configured -- resuming normal operations
[Fri Nov 17 19:09:59 2006] [notice] Server built: Jul 27 2006 15:55:03
[Fri Nov 17 19:09:59 2006] [notice] Parent: Created child process 4060
[Fri Nov 17 19:10:00 2006] [notice] Child 4060: Child process is running
[Fri Nov 17 19:10:00 2006] [notice] Child 4060: Acquired the start mutex.
[Fri Nov 17 19:10:00 2006] [notice] Child 4060: Starting 250 worker threads.

...so is there some other step I missed and is that what is making it say that ExecCGI is off in the D:/wamp/www/test.cgi ? or does this help you any to figure out what my problem is?

thanks for your time grinning smiley



Post Edited (11-18-06 02:12)

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: CyberSpatium (71.237.217.---)
Date: November 18, 2006 09:52AM

the +ExecCGI setting enabled perl support in that directory. i am not sure why you are having so many problems. I have had perl up and running with no problems with wamp so it is possible.

CyberSpatium
WAMP English Forum Admin

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: xeandor (---.brenham.tx.cebridge.net)
Date: November 18, 2006 03:48PM

could I by chance email you my config file for apache and get you to take a look at it and see if it is another option that is giving me these problems?

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: CyberSpatium (71.237.217.---)
Date: November 18, 2006 09:49PM

you dont need to. i will post the settings you need. before you do this you to make certain you need to make sure all your config files are their default settings, so to make sure, you need to uninstall wamp, then delete the wamp folder, then install wamp again. then install the active perl addon again.

after you install perl, open up your httpd.conf file, and find:
<Directory "C:/wamp/www">

#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# [httpd.apache.org]
# for more information.
#
Options Indexes FollowSymLinks



change it to this:
<Directory "C:/wamp/www">

#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# [httpd.apache.org]
# for more information.
#
Options Indexes FollowSymLinks +ExecCGI



then find:
#NameVirtualHost *:80

change it to:
NameVirtualHost *:80

<VirtualHost *:80>
ServerAdmin root@localhost
DocumentRoot "C:/wamp/www"
ServerName localhost
ServerAlias localhost
ErrorLog "C:/wamp/logs/apache_error.log"
CustomLog "C:/wamp/logs/access.log" common
<Directory "C:/wamp/www">
Options Indexes FollowSymLinks Includes +ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>



then find:
#AddHandler cgi-script .cgi

change to:
AddHandler cgi-script .cgi .pl

save the file and restart apache.


CyberSpatium
WAMP English Forum Admin

Options: ReplyQuote
Re: cgi problems in 1.6.6
Posted by: xeandor (---.brenham.tx.cebridge.net)
Date: November 19, 2006 12:48AM

thanks for all you help, its now up and running...and I think it was cuz I left the # in front of the virutal host lol... thanks for helping me figure it out though grinning smiley

Options: ReplyQuote


Sorry, only registered users may post in this forum.