|
Scripting
- So how do I use a CGI script?
- What scripting languages can I use?
- What version of perl are you running?
- Where do you keep your script interpreters and other programs?
- What CGI scripts do you provide?
- Do you support Java or JavaScript?
- Do you support Server Side Includes (SSI)?
- How about PHP?
- Do you support Microsoft FrontPage Extensions?
- How about Active Server Pages or VBScript?
- ColdFusion?
- So how do I use a CGI script?
All custom CGI scripts will need to reside in your home directory in the
public_html/cgi-bin directory.
Our web server will execute your scripts under your own username so
permissions can be set to 700.
For example, most FTP clients have the ability to execute the command:
chmod 700 script_name.
This sets the permissions of your script to be readable, writable and
executable by only your username.
Scripts can be called with the URL:
http://www.yourdomain.com/cgi-bin/script_name
or
/cgi-bin/script_name
|
- What scripting languages can I use?
You can use Perl, Bourne shell, Korn shell, PHP, and while it's not
technically a scripting language, you can use SSI. Of course, you
can always use client-side executables like Java applets or
JavaScript.
- What version of perl are you running?
Version 5.6.1.
- Where do you keep your script interpreters and other programs?
We keep our interpreters in fairly standard locations. Many Perl
and shell scripts will work with their default interpreter lines,
but if they must be changed, use the paths listed here.
The first line of your Perl scripts should read:
#!/usr/local/bin/perl
The first line of your Bourne shell scripts should read:
#!/bin/sh
Sendmail is kept in:
/usr/lib/sendmail
What CGI scripts do you provide?
HOL does not provide CGI scripts of its own.
You have the ability to run your own scripts out of your
public_html/cgi-bin directory, and
there are many public archives of common scripts available on the Internet.
Check out these archives:
nms, good replacements for FormMail and other scripts from Matt's Script Archive
HotScripts.com
CGI Resource Index
Free-Scripts.Net
Do you support Java or JavaScript?
We don't support server-side Java, but you're free to use
client-side Java or JavaScript. (Java applets are client-side Java.)
Client-side Java and JavaScript do not depend on the webserver for
any processing and can be used on any web server.
Do you support Server Side Includes (SSI)?
Yes. You can use SSI by giving your pages a .shtml extension
rather than the typical .html or .htm.
You can read more about SSI at apache.org's
documentation
site or at
ApacheWeek.
How about PHP?
Yes. Mahiai hosting offers PHP as a standard part of the service.
PHP is a scripting language that can be embedded within HTML code
for server side execution. It can easily interface with MySQL
databases, use cookies, or parse data from forms. Any pages which
need to execute PHP should use .php as the extension. For
more information on PHP, check out some tutorials on the Web:
|