Code Comments
Programming Forum and web based access to our favorite programming groups.Hello,
I have been trying to read up on using Switch.pm and using it in a Perl
script that I am trying to speed up.
Currently I have 91 if..elsif statements (See sample below) and I have
execution times of::
Server: 0.37
User: 0.09
Is there anyone that might show me how to code the first few lines to
get the ball rolling?
Sample:
==================
if ($form{'action'} eq 'new') { &new; }
elsif ($form{'action'} eq 'clientfinder') {&clientfinder();}
elsif ($form{'action'} eq 'tracking') { &tracking(); }
elsif ($form{'action'} eq 'proctracking') { &proctracking(); }
# elsif statements -sniped-
else { &cat; }
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.