Frequently Asked Questions
Common CGI questions and problems
The most common problem that people have with cgi scripts is the permissions on the script. In order for a script to run, it must have execute permissions. If you are getting this error:
You don't have permission to access /cgi-bin/test.pl on this server.
You need to change the permissions to '755'. You can do this with most ftp clients, or through ssh.
The next most common problem is the 'mode' that you upload the script in. (i.e., from your editor to the server). You need to configure your ftp client to upload ".cgi" and ".pl" files in "ASCII" mode. The error you will recieve if you do not upload in ASCII mode is:
Premature end of script headers: /home/you/cgi-bin/script.cgi
If you still are getting an error message, chances are that there is a syntax error in your script. To find out what the error is, you should 'ssh' into your account, and run the perl interpreter on the script.
- How to ssh into your account: (in win95/98)
You will need to install an SSH client.Level Ten Hosting recommends putty, a free windows client - How to check for syntax errors in a script.
You will need to install an SSH client .Level Ten Hosting recommends putty, a free windows client.- 1. Log into your account through ssh. (see above)
- 2. Assuming your script is in 'cgi-bin', type "cd www/cgi-bin", hit enter.
- 3. Type "perl scriptname.cgi" where 'scriptname.cgi' is the name of the script.
- 4. Perl will tell you what is wrong with the script. Make the recomended changes.

Chat With Us
We’re always here for you
Our Support staff is ready to answer any questions you may have 24/7.
Contact us today!
Powerful Servers
- P4 2.8 GHz or faster
- PC3200 DDR RAM
- Dual hard disks - SCSI / IDE
- Raid level 5

