X-Git-Url: http://git.shiar.nl/gitweb.cgi/perl/plp/.git/blobdiff_plain/756d5de12d15296e7689a7c5c7b5e35bd0bccb0e..5d1c2193a6c3c98cf426e03eb783eace183e5a0c:/PLP.pm?ds=inline diff --git a/PLP.pm b/PLP.pm index 52fba51..a919cb7 100644 --- a/PLP.pm +++ b/PLP.pm @@ -1,8 +1,6 @@ package PLP; -# Not to be used without the CGI script; - -our $VERSION = '3.04'; +use 5.006; use PLP::Functions (); use PLP::Fields; @@ -10,174 +8,496 @@ use PLP::Tie::Headers; use PLP::Tie::Delay; use PLP::Tie::Print; -=head1 PLP +use File::Basename (); +use File::Spec; -None of the functions in this module should be called by PLP scripts. +use strict; -Functions: +our $VERSION = '3.19'; -=over 10 +# Subs in this package: +# _default_error($plain, $html) Default error handler +# clean Reset variables +# error($error, $type) Handle errors +# everything Do everything: CGI +# handler($r) Do everything: mod_perl +# sendheaders Send headers +# source($path, $level, $linespec) Read and parse .plp files +# start Start the initialized PLP script -=item sendheaders +# The _init subs do the following: +# Set $PLP::code to the initial code +# Set $ENV{PLP_*} and make PATH_INFO if needed +# Change the CWD -Sends the headers waiting in %PLP::Script::header +# This gets referenced as the initial $PLP::ERROR +sub _default_error { + my ($plain, $html) = @_; + print qq{
},
+ qq{Debug information: $html |
\n