get '/' => sub { my $c = shift; $c->render( template => 'index' ); }; post '/' => sub { my $c = shift; my ($opt) = $c->param('option'); app->log->info("Option $opt"); my $result = do_something($opt); $c->render( template => 'result', c => $result ); }; #### @@ index.html.ep %layout 'default';



##
## @@ result.html.ep %layout 'default';

Result

<%= $c %>