View Single Post
Old 2nd August 2009, 02:40
jamesls jamesls is offline
Join Date: Apr 2009
Posts: 33
Thanks: 1
Thanked 0 Times in 0 Posts
Default accessing CGI-BIN / odd script behaviour

I have a script that works fine when I run it on my debug machine but when I upload it to my ispconfig machine I have problems accessing it.

I'm running ubuntu 8.10 & ispconfig 3

The script is a PHP script, and is in my cgi-bin folder.
The script will run ok if its run at the start of the web page.
if I place the script in a form action it can't find the script.

The web layout is the default ispconfig, I use 'include "../cgi-bin/script.php" '
at the start of the page, (it sets up sessions) it'll work fine with no problems.

I place the same ../cgi-bin/script.php in a forms action and it gives me an error - page not found.

I've commented out everything within the script apart from a page redirect
header (Location: ../page02.php )

if I put the script in the same folder as the web pages (web) it all works fine.
I've tried various paths and the ../cgi-bin/script.php works at the top of a page but not if I put it in a form action.

It will work in the form action if I place it in the same folder as the web pages and change the form action /script.php.

Am I address the cgi-bin folder correctly?
The read, write, exeute for the cgi-bin folder & web folder appear to be the same.

I'm puzzled as to why it won't work when I call the script from a form if the script is in the cgi-bin folder.

Any help would be apreciated

Reply With Quote
Sponsored Links