Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Having some problem with Perl configuration about .cgi files

Status
Not open for further replies.

sm840817

Programmer
Jun 29, 2003
4
US
Hi, I¡¯m a newbie who just started to learn Perl programming. But I have this problem that I¡¯ve been working for last 3 days
I think I installed the active state package properly and .pl files runs just fine on web browser, but not .cgi files. It keep opens as a regular file, which opens up for download. Why is that? It¡¯s driving me crazy! Please help me!

more info: both .pl .cgi files runs just fine at command line, but .cgi doesn't work properly on a web browser.

OS = Windows XP
Server Program = Abyss Webserver

 
See the FAQ section
misbarbell (Barbie) has probably answered your question already

--Paul

It's important in life to always strike a happy medium, so if you see someone with a crystal ball, and a smile on their face ...
 
Pardon my newbiness, but i thought since i am running on my own server, i didn't have to specify the permissions. Am i right? if it's not, how can i change it? Thank you =)
 
sm#### (numberz a bitz, and I always get em wrong)

Chances are that you're not giving us enough informaton to help you solve your isuue

What errors are you getting in the error log?

--Paul

PS prem end headers -? print "Content-Type: teext/hrml";
 
For previous post please read
PS prem end headers -? print "Content-Type: text/html";






It's important in life to always strike a happy medium, so if you see someone with a crystal ball, and a smile on their face ...
 
Paul is probably right, the only times I experienced a CGI download prompt was when I was trying to print to screen before I printed out the proper headers (or when I totally forgot about them). I never get prompted due to permission settings though, not sure if it would happen under those circumstances.

"Age is nothing more than an inaccurate number bestowed upon each of us at birth as just another means for others to judge and classify us- sulfericacid
 
Running windows means there aren't executable permissions, per se. The webserver still has to have permission to read the script and permission to execute perl, but there's not 0755 to set.

The webserver also has to know how to execute perl with a given script. Apache works best with the shebang line pointing to where the perl interpreter is located. In windows, Apache also lets you use the registry's file associations with it. I've not used IIS or Abyss, but I know there are FAQ's available here on the first two.

Also, read through the software's documentation, too:
----------------------------------------------------------------------------------
...but I'm just a C man trying to see the light
 
Thank you everyone for such a generous replies! =)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top