spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / web / programming / perl / 101 / troubleshooting

Trouble Shooting

Developer News
Mandrake Linux Founder Back, Virtually
Amazon: We're a Technology Company
Sun Expands MySQL With Closed Source

Perl 101

The best thing to do is to first try and determine where your error occurred. Did it occur when you tried to execute the script? If so, make sure that you transferred the file in ASCII or text format. Then check that you set the appropriate permissions for the script. Finally, see that the first line of your program points to your Perl interpreter. If the error occurred after you edited some variables, odds are that you made a typo or specified an invalid path.

Things to remember:

  • Scalar variables should look like this:
    $VariableName = "String";
    Make sure you have the string surrounded in quotation marks and the line is terminated with a semi-colon.
  • Make sure you check with your ISP to find out your server path and to see where/whether you are allowed to execute Perl scripts.
  • Always transfer your files in ASCII or text mode.
  • When in doubt consult your server’s log files. They will often contain important messages that can help you debug a program.

Common Server Errors and what they mean:

"403 Forbidden"
This is tells you that the file/directory permissions, are most likely, set incorrectly.

"404 File Not Found"
This means that you are trying to access a file that does not exist on the server. Double check your URL and where you put the file. Remember some servers are case sensitive (Unix).

"500 Server Error"
This is the bad one. This means that your program is producing output that your server cannot understand. Check your server’s log files to see if they help at all, and more importantly, look over your variables again to make sure that you did not make any typos.

# # # # # #

Scott Phillips is a founding partner and Chief Technology Officer for The Reflector Group, a New York City-based new media firm specializing in client services and original content programming. Mr. Phillips' responsibilities range from designing websites to developing innovative technology-based strategic solutions. He is a graduate of Hamilton College.

Comments are welcome

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Tech Jobs | Shopping | E-mail Offers

webref The latest from WebReference.com Browse >
Working with the DOM Stylesheets Collection · Administering RBAC in PHP 5 CMS Framework · xref: Automatic Cross Referencing Script
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Combine BottomCount() with Other MDX Functions to Add Sophistication · Creating a Daemon with Python · The Coming Voice-over-WiMAX Revolution


Revised: May 8, 1998

URL: http://webreference.com/programming/perl/101/trouble.html