NAME
Mojolicious::Controller - Controller Base Class
SYNOPSIS
use base 'Mojolicious::Controller';
DESCRIPTION
Mojolicous::Controller is a controller base class.
METHODS
Mojolicious::Controller inherits all methods from MojoX::Dispatcher::Routes::Controller and implements the following new ones.
app
my $app = $controller->app;
render
$controller->render;
$controller->render(action => 'foo');
render_partial
my $output = $controller->render_partial;
my $output = $controller->render_partial(action => 'foo');
req
my $req = $controller->req;
res
my $res = $controller->res;
stash
my $stash = $controller->stash;
my $foo = $controller->stash('foo');
$controller = $controller->stash({foo => 'bar'});
$controller = $controller->stash(foo => 'bar');
url_for
my $url = $controller->url_for;
my $url = $controller->url_for(controller => 'bar', action => 'baz');
my $url =
$controller->url_for('named', controller => 'bar', action => 'baz');