basically, i have an application that checks the status of a user account on
the system.  if it's active, i'd like to show a run mode that allows me to
modify its properties (expiration date, billing type, add comments, etc), but
if it's inactive, i'd like to show a different page (switch run modes) which
only allows you to add comments and reactivate the account (by resetting the
password).

i would also like to use this method for returning error pages based on some 
condition(s).

the example you gave is what i'm currently implementing, but it just doesn't
seem right because it looks as though i'm not actually changing run modes,
but i'm nesting into another method temporarily, and then jumping out.  is
this a correct interpretation, or am i way off base here?

thanks,
  twkonefal

--- Kenny Pyatt <[EMAIL PROTECTED]> wrote:
> Can you tell us more about what you are doing. CGI::App offers a 
> framework that helps you handle which run-mode (state) you want the 
> application to be in. This may answer your question but I don't think it 
> is really what you want.
> 
> sub Start
> {
> my $self = shift;
> 
> if ($foo)
> {
> return $self->DifferentMode();
> }
> else
> {
> # Get a template and display it.
> my $template->load_tmpl('template.html');
> return $template->output();
> }
> }

______________________________________________________________________ 
Web-hosting solutions for home and business! http://website.yahoo.ca

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to