Sample Perl script for testing

A sample Perl script for testing on your account.

The following Perl script is bug free and can be used for testing if Perl is working on your account.


# -- my first perl script!

print "Content-type: text/html\n\n";

print <<"EOF";

<TITLE>Hello, world!</TITLE>

<H1>Hello, world!</H1>

  1. Create a new file and copy the above script into it
  2. Save it as “hello.cgi” or “”
  3. With your FTP program
    1. Upload it to your “public_html” folder
    2. Change the modification privileges (chmod) to 755
  4. Try access it in your web browser (e.g.
Posted 2008-03-25 in Web Development