You can set your own runmode evaluator by passing mode_param a subref as in:In the examples I saw there seemed to be only one possible event generatedper form. This is fine for an example, but most forms have a number ofevents that could be generated (hyperlinks, form buttons, image buttons, etc.)What are some of the way events are modeled within a CGI::Application program, with the emphasis on having one out of many possible events being generatedfrom the same run-mode?
sub setup
{
my $self=shift;
$self->start_mode('login');
$self->mode_param(\&getMode);
$self->run_modes(
login=>\&login,
....
I use it to differentiate between different user types based on login.
That way, I can authenticate different runmodes based on the user type
(and make sure they are playing in their own sandboxes). Additionally,
you could have additional parameters that modify the runmode as in:
index.pl?runmode=ShowSomething&submode=ShowOnlyCompleteFields
--------------------------------------------------------------------- Web Archive: http://www.mail-archive.com/suppressed/ To unsubscribe, e-mail: suppressed For additional commands, e-mail: suppressed
><><><><><><><><>< AgentM suppressed --------------------------------------------------------------------- Web Archive: http://www.mail-archive.com/suppressed/ To unsubscribe, e-mail: suppressed For additional commands, e-mail: suppressed
Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.