Home l Hosting Plans l Services l Portfolio l Graphics I Animation I Contact l FAQ l Support I Special

 
CGI and Perl

Where is sendmail, perl, and date located?
Some CGI scripts require to supply the system path to certain system binaries.   Here is some information you may need:

Sendmail /usr/sbin/sendmail
Perl /usr/bin/perl
Date /bin/date
Remote Host Directory /yourusername-www/
Script URL http://www.yourdomain.com/cgi-bin/script.pl
Home directory /home/yourusername/yourusername-www/

What version of perl do you support?
We currently support Perl version 5.0.   Because Perl 5.0 is backwards compatible with Perl version 4.0, there is no reason for us to offer version 4.0

What file extensions can I use for CGI scripts with your servers?
When you use CGI scripts with our Unix servers, you need to give them either a .cgi or a .pl extension.  Otherwise, the web server will not recognize them as cgi scripts and will display them like a text file or a .html document.

What do I need to fix if I'm getting a "500 Internal Server" error?
There are several reasons that you could be getting this error.

First, make sure you read ALL of the instructions that came with the CGI script.

Second, make sure that you upload your CGI script in ASCII format.   Your FTP client should allow you to choose between either ASCII(or plain text), Binary(or images), or auto.  Select ASCII.  If you upload your CGI script in Binary mode, it will put a "^M" at the end of every line in the file, which causes problems with CGI scripts.

Third, if your CGI script is a perl script, make sure the top line says:
#!/usr/bin/perl

Fourth, contact the author of the script, many scripts have user help forums for people who are having trouble installing a program.

What do I need to fix if I'm getting a "Forbidden" error?
This error is usually caused by an error with permission settings.  You will need to download a program like WS_FTP which allows UNIX CHMOD's via FTP.  You can download WS_FTP for free from http://www.tucows.com/.   Once you have installed WS_FTP, connect to your site and find the cgi script you need to fix.   click your right mouse button on it(on the server side, not the one on your hard drive), then select "chmod (UNIX)".  It will open up a window with 3 boxes, owner, group, and other.  In each of those boxes, you will have 3 choices, read, write, and execute.  Most cgi scripts need to be set to read/execute to work correctly.  When your CGI documentation requires you to set the permissions to 755, it will have these permissions:

owner - read, write, and execute
group - read, and execute
other - read, and execute

When it asks you to set the permissions to 777 it will have these permissions:

owner - read, write, and execute
group - read, write, and execute
other - read, write and execute

How do I use Server Side Includes?
We do support server side includes.  The syntax for a Server Side Include looks like this:

<!--#<tag> <variable>-->

So a practical example is to include a file, eg. test.txt into a page.
The syntax for it is:

<!--#include virtual="test.txt"-->

To show the date of the last time the html document was updated, you can use a SSI like this:

<!--#echo var="LAST_MODIFIED"-->

 

 
     
Home l Hosting Plans l Services l Portfolio l Graphics I Animation I Contact l FAQ l Support I Special

© Interweave Web Design