CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner:
Permission Denied



Feb 22, 2000, 4:03 PM

Post #1 of 5 (1954 views)
Permission Denied Can't Post

I am new to perl and cgi (trying to get through the basics). I have copied a perl script that is supposed to allow information from a form to be posted, but when the submit button is pushed, I get exec()returned: 13: Permission Denied. I believe that I have the path to perl correct perl/bin (location of perl.exe) and that is at the top of my page. My script is in a cgi-bin obviously. I tried to set the permission with chmod 755 but 1. is this only for unix and 2. where would i locate the command in my script?
Any help is appreciated


Feb 22, 2000, 6:50 PM

Post #2 of 5 (1954 views)
Re: Permission Denied [In reply to] Can't Post


Yes you only need to chmod folders and directories on unix platforms and a few other unix type platforms like linux, and the path to perl for unix is





depending on your server it will be one of those. Most likely the first one.

You should post your script so people can look at it. I can't begin to tell you how to fix you program without seeing it. I may not be able to tell what your problem is but if you post it at least others will be able to take a look.



Feb 23, 2000, 1:19 AM

Post #3 of 5 (1954 views)
Re: Permission Denied [In reply to] Can't Post

ok here it is


chmod 755

# Get HTML header, ender, define the page title.

# Get the query string.

$QueryString = $ENV{'QUERY_STRING'};

@NameValuePairs = split (/&/, $QueryString);

# Put up an HTML Header, page title and a rule.

print "BODY>\n";
print "<H1>&Title</H1>\n";
print "<HR>\n";

# Split each of the name-value pairs and print them on the page.

foreach $NameValue (@NameValuePairs)
($Name, $Value) = split (/=/, $NameValue);
print "Name = $Name, value = $Value<BR>\n";

# End

Now does the first command have to be like that, it can't resemble my first line?


Feb 23, 2000, 3:18 AM

Post #4 of 5 (1954 views)
Re: Permission Denied [In reply to] Can't Post

Comment out:

chmod 755


#chmod 755

It looks like you trying to have the scripts chmod itself. This needs to be done another way i.e tenet, console

Brian Hayes


Feb 23, 2000, 2:02 PM

Post #5 of 5 (1954 views)
Re: Permission Denied [In reply to] Can't Post

Thanks for the help here, but I figured it out. The only problem was I had to set the chmod permission through WS_FTP once the script was in the cgi-bin. It was a matter of right-clicking on the file and changing the permission to execute for all.


Now that I can get the information to post back to the visitor of my page, how do I get the information back to me? That will be my next challenge. Once again, thanks for the help, and I'm sure you'll see reefland back here with a new topic.


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives