X-Git-Url: http://git.shiar.net/perl/plp/.git/blobdiff_plain/aaf82199178b7ad9117942bafcb45fadc24e1dab..b5e0ee87251670be18b2f2fc128a4be0b25ebfb8:/lib/PLP.pm diff --git a/lib/PLP.pm b/lib/PLP.pm new file mode 100644 index 0000000..03c4acb --- /dev/null +++ b/lib/PLP.pm @@ -0,0 +1,499 @@ +package PLP; + +use 5.006; + +use PLP::Functions (); +use PLP::Fields; +use PLP::Tie::Headers; +use PLP::Tie::Delay; +use PLP::Tie::Print; + +use File::Basename (); +use File::Spec; + +use strict; + +our $VERSION = '3.19'; + +# 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 + +# 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 + +# This gets referenced as the initial $PLP::ERROR +sub _default_error { + my ($plain, $html) = @_; + print qq{
},
+ qq{Debug information: $html |
\n