Optiperl not seeing Apache

I have a stand alone PC, running windows XP Pro and Apache4 with Optiperl5 and setup my entire web site on the PC to run as an off line web. Apache is running fine and my pages load and display OK, but Optiperl will not see Apache and my cgi's will not run. When I run a script it just shows the script text on my browser.

Answer:
Make sure the setting "Server / Run with server" is enabled. For more information, see http://www.xarka.com/optiperl/help/usingapache.htm

* The option "2 (External ...)" at the bottom of the Server menu should also be enabled.

If it's enabled and apache is running, optiperl should be running the test script (when pressing F9 or Run / Run in browser) by requesting a URL similar to http://127.0.0.1/cgi-bin/script.pl .

So after running, see the "html" tab of the browser window.

Also, does apache work by itself OK? From any browser (not optiperl) enter http://127.0.0.1/index.html. This should show the file apache\htdocs\index.html.

http://127.0.0.1/cgi-bin/script.pl should execute script.pl in apache\cgi-bin. You can copy into this folder any example script from optiperl's webroot folder. Just make sure first to change the first line to something like:

#!c:\perl\bin\perl.exe

or wherever the path to perl is.

Note also that if you are not using a project, enter the correct options under Tools / Options / External server. If you are using a project, enter under Project / Options.

Reply:
My problem was the Apache ScriptAlias directive was not set up right as I was trying to  run scripts form my local website cgi-bin and Apache was set to the Apache/Apache2/cgi-bin.

06.07.2005. 00:02

This article hasn't been commented yet.

Write a comment

:

:

:


2 + 9 =