Problems with CGI

Roadie

Verified User
Joined
Jul 16, 2004
Messages
5
Location
The Netherlands
Okay I know this isn't really the right place for my question, but maybe the're someone around to help me out...

If programmed a bunch of cgi-script on my dev box. After uploading it seemed really scewed. My main problem is that a link to a perl script works fine in a browser, but does not if it is called from winthin a .shtml page.
Does anyone of you have an idea ?

Best shown in :
http://www.winkelcentrumvlissingen.nl/indexnieuw.shtml

while the scripts seem to work fine:
http://www.winkelcentrumvlissingen....even/weergeven.pl?file=prijsvraag&action=html

Other scripts (without the questionmark) seem to work right.

Sorry for the dutch content :p

thanx a lot
Roadie
 
I had the same problem, and found by looking at the apache error logs, that my server was attempting to read all cgi scripts out of the /var/www/cgi-bin directory and would not attempt to pull a script from inside my public_html directory.
 
Okay partitional it solves things...

the log says...
[Sat Jul 17 09:05:23 2004] [error] [client 24.XXX.255.XXX] invalid CGI ref "cgi-bin/XXX/weergeven/weergeven.pl?file=evenementen&action=cgi" in /home/XXX/winkelcentrumvlissingen.nl/public_html/content.shtml

I tried serveral ways of executing the script but nothing seems to work correct.

Maybe thuskey can tell me how he solved the problem?

I've tried to call the script from .shtml with:

<!--#exec cgi="/home/XXX/domains/winkelcentrumvlissingen.nl/public_html/cgi-bin/XXX/weergeven/weergeven.pl?file=prijsvraag&action=cgi"-->
<!--#exec cgi="/cgi-bin/XXX/weergeven/weergeven.pl?file=prijsvraag&action=cgi"-->
<!--#exec cgi="cgi-bin/XXX/weergeven/weergeven.pl?file=prijsvraag&action=cgi"-->
<!--#exec cgi="http://winkelcentrumvlissingen.nl/cgi-bin/XXX/weergeven/weergeven.pl?file=prijsvraag&action=cgi"-->

So now I'am out of options...

Greetings for now...

Roadie
:confused: :confused:
 
Last edited:
It appears we are not using the same commands at all. I used:

<!--#include virtual="/cgi-bin/myperlscript.pl" -->

It only worked when I had it in the /var/www/cgi-bin/ directory, or whichever directory is the cgi-bin for the default apache server.
 
oh and just a quick note, using php and the include and include_once commands for all this stuff turned out being much easier and alot less limited. I just haven't had time to convert my old SSI stuff to php, but one day I will.
 
TNX A LOT !!!


Seems to work as planned now !

Maybe you are right about php, but that's a new language to me... so that will take a lot of testing time :(

I've learned a lot, tnx again !


Roadie
 
Back
Top