Embperl - building dynamic websites with Perl


Runtime configuration
[ << Prev: DESCRIPTION ] [ Content ] [ Next: Execute >> ]

The runtime configuration is done by setting environment variables, in your web server's configuration file. Basically the configuration is the same as for normal Embperl. All Embperl configuration directives also applies to Embperl::Object. There are a few additional configuration directives listed below. Addtionaly you have to set the PerlHandler to Embperl::Object when running under mod_perl or use epocgi.pl instead of embpcgi.pl when running as CGI Script.



EMBPERL_DECLINEtop

Perl regex which files should be ignored by Embperl::Object



EMBPERL_FILESMATCHtop

Perl regex which files should be processed by Embperl::Object



EMBPERL_OBJECT_BASEtop

Name of the base page to search for



EMBPERL_OBJECT_STOPDIRtop

Directory where to stop searching for the base page



EMBPERL_OBJECT_ADDPATHtop

Additional directories where to search for pages. Directories are separated by ; (on Unix : works also). This path is always appended to the searchpath.



EMBPERL_OBJECT_FALLBACKtop

If the requested file is not found the file given by EMBPERL_OBJECT_FALLBACK is displayed instead. If EMBPERL_OBJECT_FALLBACK isn't set a staus 404, NOT_FOUND is returned as usual. If the fileame given in EMBPERL_OBJECT_FALLBACK doesn't contain a path, it is searched thru the same directories as EMBPERL_OBJECT_BASE.



EMBPERL_OBJECT_HANDLER_CLASStop

If you specify this call the template base and the requested page inherit all methods from this class. This class must contain Embperl::Req in his @ISA array.



EMBPERL_OBJECT_APPtop

Filename of the application object. The file should contain the Perl code for the application object. The must be no package name given (as the package is set by Embperl::Object), but the @ISA should point to Embperl::App. If set this file is searched through the same search path as any content file. After a successful load the init method is called with the Embperl request object as parameter. The init method can change the parameters inside the request object to influence the current request.

The init method should return zero or a valid HTTP status code (e.g. return 302 and set the location header in %http_headers_out)


[ << Prev: DESCRIPTION ] [ Content ] [ Next: Execute >> ]


© 1997-2023 Gerald Richter / actevy