Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^2: In CGI::Application cgiapp_prerun vs. cgiapp_init?

by weierophinney (Pilgrim)
on Dec 12, 2005 at 17:35 UTC ( [id://516067]=note: print w/replies, xml ) Need Help??


in reply to Re: In CGI::Application cgiapp_prerun vs. cgiapp_init?
in thread In CGI::Application cgiapp_prerun vs. cgiapp_init?

The order of operations you provide does a better job at explaining this than your statement, "cgiapp_init() is called once by new, while cgiapp_prerun() is called everytime a request comes in".

Basically, cgiapp_init() is called as the object is first created in order to setup the environment for the application. cgiapp_prerun() is called prior to executing the selected run mode for a given request. I typically use cgiapp_prerun() to check if the run mode is allowed at this point by this user -- i.e. I use cgiapp_prerun() as the place to implement ACLs.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://516067]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (2)
As of 2024-03-19 04:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found