use strict; use warnings; use Mojolicious::Lite; our %subject = ( Yes_bus => 'Branch Manager Business Call', No_bus => 'Merchant Referral', ); get '/' => sub { my $self = shift; my $selection = $self->param( 'businessCall' ); $self->stash( selection => $selection, subject => $subject{$selection} ); $self->render( template => 'index' ); }; app->start; __DATA__ @@ index.html.ep
% if ($selection) { You picked <%= $selection %> which yields: <%= $subject %> % }