Forum

PATH_INFO woes

Duke Normandin
19 December 2010, 22:48
Using latest Hiawatha on latest Xubuntu

I have a test CGI script with this link:

http://www.my-domain.com/cgi-bin/perl/print_ev.cgi/direction=North/speed=slow

direction=North/speed=slow should show up in PATH_INFO - but it does not!

I have set EnablePathinfo = yes

and restarted Hiawatha. No joy!

Clues please! TIA...
Duke Normandin
20 December 2010, 14:33
I think I might have found the cause of my problem after reading:

http://www.hiawatha-webserver.org/forum/topic/691

I commented out the alias setup line in my VH section
FollowSymLink is enabled

However I still get a 404 page.

Maybe I'm not creating the symlinks properly.

here's what i have:

dnormandin:/var/www/hiawatha/site1$
ls -l
total 8
lrwxrwxrwx 1 root root 44 2010-12-20 06:25 cgi-bin -> /home/dnormandin/www/site1/cgi-bin
drwxr-xr-x 3 root root 4096 2010-12-18 22:41 htdocs
drwxr-xr-x 2 root root 4096 2010-12-06 13:46 log

The /var/www/hiawatha/site1/cgi-bin/ directory doesn't actually exist. There's only a cgi-bin link in /var/www/hiawatha/site1/. Is that OK? Or do I have to create the /var/www/hiawatha/site1/cgi-bin/ directory, and then put the link in it? I tried both, but 404 is all I get. worked OK before using an alias. TIA..

Duke Normandin
20 December 2010, 16:38
I solved the problem

Indeed, it appears that EnablePathInfo does not work for "aliased" directories.

So I too used a symlink - which I finally got to work correctly.
Hugo Leisink
20 December 2010, 19:55
I know PATH_INFO doesn't work with alias. If it was for me, PATH_INFO would exists at all. It's such an ugly thing. But a lot of old web applications still depend on it.
Duke Normandin
21 December 2010, 15:27
But a lot of old web applications still depend on it.

and it is still part of the CGI standards, is it not?
Hugo Leisink
21 December 2010, 15:29
I hate to say it, but yes.
Duke Normandin
23 December 2010, 16:30
Merry Christmas!

To you and yours...

and all the best in the New Year!
This topic has been closed.