Quantcast

Singapore Web Hosting

Singapore Web Hosting - hosting menu

Singapore Web Hosting - Hosting menu

Singapore Web Hosting

Home » Support » FAQ



Singapore dedicated servers


Frequently Asked Questions - General FAQ

 

General FAQ


What is CGI?

CGI stands for Common Gateway Interface. Essentially it is a place where the Web server knows executable content lives.

What is Perl?

Perl stands for Practical Extraction and Report Language. It is the most widely used language for CGI.

What is SSI?

SSI stands for Server Side Include. The Webserver parses an SSI enabled document and interprets SSI directives.

Can I use CGI in conjunction with HostSG services?

Yes. Each account is setup with a cgi-bin directory where cgi programs live.

Can I use Perl scripts in conjunction with HostSG services?
Yes. Perl scripts can be run from the command prompt like so: ./myscript.pl or perl5 myscript.pl


Where is Perl located and what version(s) do you support?

Unix:

Version 5.005_03: /usr/bin/perl

Windows 2000
Perl 5 Win32 Version by Active State.
WIN32 : c:\Perl\bin\perl.exe

Where is Sendmail located?
/usr/sbin/sendmail

Do you have any pre-made CGI scripts that I can use?

We install the following pre-made CGI scripts onto all our Unix Hosting accounts.

formmail - a script that accepts form input and mails it to a e-mail address specified in the html document.
textcounter - allows a text count of page accesses
guestbook - allows users to post messages to webpage.

What if my CGI script isn't working?

Here are some common CGI traps:

Check the error log - it will often give you a line number and an error to work with - if it just says "Premature end of script headers" check the following: Check the permissions - Make sure that the script is *only* writeable by the owner - not group or world.

Check that the script is pointing to the correct location of perl5 (/usr/bin/perl).

Check to make sure that the script is outputting the correct header: Content-type: text/html\n\n is the most common for cgi scripts that output HTML.

Check to make sure that the script was saved as a unix file type (in the case of unix servers). Windows and Unix have different line ending characters. While windows file types won't break most html - they will break most cgi's that are on unix servers.

Where is the error log?

We do not provide error log files due to security reasons.

Can I use any CGI script?

We allow users to write and run their own cgi-scripts, but we reserve the right to disallow scripts that have harmful server side effects (ie. a persistant script).

Can I use CGI and Perl to read and write files?

Yes, you can use Perl and CGI to read and write files.

Does my server allow me to run CGI scripts outside of a cgi-bin directory?


Yes, if your account is on a UNIX server. (Note: in order to have your CGI script run automatically outside of the cgi-bin directory, it must have been named and saved with a ".cgi" extension.)

Does HostSG support third party scripts?

We allow their use, but support for proprietary software needs to come from the author of the software.