[cgiapp] CGI::Application and CGI::Application::Dispatch::PSGI
Ron Savage
ron at savage.net.au
Wed Jan 4 18:02:01 EST 2012
Hi Folks
OK. I'm finally at the point of using CGI::Application V 4.50.
In the past I combined CGI::Application and
CGI::Application::Dispatch::PSGI like this:
<---8><--->
use CGI::Application::Dispatch::PSGI;
use Plack::Builder;
# ---------------------
my($app) = CGI::Application::Dispatch -> as_psgi
(
prefix => 'Local::Application::Controller',
table =>
[
'' => {app => 'Initialize', rm => 'display'},
':app' => {rm => 'display'},
':app/:rm/:id?' => {},
],
);
builder
{
enable "ContentLength";
enable "Static",
path => qr!^/(assets|favicon|yui)/!,
root => '/dev/shm/html';
$app;
};
<---8><--->
where Local::Application::Controller looked like:
<---8><--->
package Local::Application::Controller;
use parent 'CGI::Application';
...
<---8><--->
The docs for CGI::App which discuss PSGI support do not provide me
enough info...
So, what do I have to change to use the newer style CGI::App?
TIA.
--
Ron Savage
http://savage.net.au/
Ph: 0421 920 622
More information about the cgiapp
mailing list