Two quick questions... Why is the name for the function "controller_edit" instead of "controller_save"? Why is post_only checked as part of the dispatch and not inside the two functions?
Quickie older-style perl alternative structure where I use AUTOLOAD to figure out the exists/can situation:
use strict;
use warnings;
package Controller;
sub search {...}
sub view {...}
sub save {...}
sub delete {...}
sub AUTOLOAD {
# Do index stuff
}
...
package main;
...
my $method = $q->param('do');
Controller->$method;