in reply to CGI Design

Check out CGI::Application. You may find some great ways to clean up your code and use better dispatch methods.