NAME

Squatting::On::MP13 - a handler for Apache 1.3's mod_perl

SYNOPSIS

First, load the App + Squatting::On::MP13:

<Perl>
  use App 'On::MP13';
  App->init;
</Perl>

Then, setup a handler in your Apache config:

<Location />
  SetHandler  perl-script
  PerlHandler App
</Location>

Alternatively, if your mod_perl has method handler support, you can say:

<Location />
  SetHandler  perl-script
  PerlHandler App->mp13
</Location>

VirtualHost configuration using Pod::Server as an example:

<VirtualHost *:80>
  ServerName   podserver.mydomain.org
  DocumentRoot /www/podserver.mydomain.org
  ErrorLog     logs/podserver.mydomain.org-error_log
  CustomLog    logs/podserver.mydomain.org-access_log common
  <Perl>
    use Pod::Server 'On::MP13';
    Pod::Server->init;
  </Perl>
  <Location />
    SetHandler  perl-script
    PerlHandler Pod::Server
  </Location>
</VirtualHost>

DESCRIPTION

The purpose of this module is to add an mp13 method to your app that can be used as a mod_perl method handler. It also adds a conventional mod_perl handler so that Squatting apps can be deployed on mod_perl installations that don't have method handler support built in. To use this module, pass the string 'On::MP13' to the use statement that loads your Squatting app. Also, make sure you've configured your Apache to use App->mp13 as the handler.

API

They should have stopped at Apache 1.3.37.

App->mp13($r)

This method takes an Apache request object, and translates the request into terms that Squatting understands. Then, after your app has handled the request, it will send out an HTTP response via mod_perl.

App::handler($r)

Unfortunately, it is common for mod_perl to not have method handler support compiled in, so a more conventional mod_perl handler is also provided. This just calls App->mp13($r).

(Note that this sub is added directly to the App that loaded Squatting::On::MP13. It's App::handler and NOT App->handler.)

SEE ALSO

Squatting::On::MP20

Apache, mod_perl, mod_perl_method_handlers