#!/usr/bin/perl use warnings; use strict; MyApp->new->run; package MyApp; use base qw(CGI::Application); use CGI::Application::Plugin::AutoRunmode; sub mySub : Runmode { return "Hello from mySub\n"; } #### $ ./runmode.cgi rm=mySub Content-Type: text/html; charset=ISO-8859-1 Hello from mySub