Electric Type

Multimedia

About Us

News

Help

Intro to Mod_Perl

Page 9 — Fixing Bugs

Now that we've got enough background to code using mod_perl, let's take a quick look at what to do when something goes wrong. The first and most important place to start debugging is in the server's error log. For example, if your module does not end with 1; or return true, you may find something like this in your error log.
[Sun Sep 13 21:07:43 1998] [error] Apache/Add_Header.pm did not return a true value at (eval 4) line 2.
Based on this information, we can get an idea of where to look for the error.

If you had a syntax error in your script, you'll also know where to find it:

[Sun Sep 13 21:43:34 1998] [error] Missing right bracket at /usr/lib/perl5/site_perl/Apache/Add_Header.pm line 71, at end of line
If you correct your code, but that doesn't seem to have any impact on how the script is executed, remember that scripts are cached in memory and they stay there until told otherwise. So to check your changes, send your server the HUP signal handler to have it recompile all the modules.

next page»


Dynamic HTML  

Frames  

HTML Basics  

Stylesheets  

Tables  

XML  

Javascript  

Database Connections  

Intro To Perl  

HTML 4.0  

User Blogs

Screen Shots

Latest Updates

Contact Us

Valid HTML 4.01!
Valid CSS!

Breadcrumb

© ElectricType
Maintained by My-Hosts.com
Site map | Copyright | Disclaimer
Privacy policy | Acceptable Use Policy
Legal information.