Responses below... thanks for the look/input!
Mark Stosberg wrote:
On 2005-09-22, Jason Purdy <[EMAIL PROTECTED]> wrote:
However, this shouldn't require a session system, because I don't
currently need one. It would be nice for the session system to be
optional.
The user could declare through the API that they don't want the messages
to persist.
Yeah, I can put that on a TODO. The persistence is useful for messages
that aren't scoped for the runmode of the subsequent request.
The docs say: "[ the clear_messages() ] method will be called
automatically when the Plugin puts it into your template." but I don't
see that happening in the code.
I forgot about that - d'oh! Actually, I had that in the original
design, but the more I played around with it, the more I didn't like the
idea. I'm thinking I should update the docs accordingly and put a TODO
on my list to allow the developer to configure if messages are cleared
or not.
If that's true, the session could be required lazily. If you get to
cgiapp_postrun() and there is anything left in the message stack, /then/
it would require a persistent session to stuff them into. Otherwise, no
persistence was necessary.
I'm not sure whether I like the sneakiness of passing parameters to the
template through a backdoor, but it may grow on me.
Oh, but that's the neat part. :)
Looking at the bigger picture, I'm not sure I'd use this plugin with
more of tutorial explaining its usefulness. Right now I'm in a state of
blissful ignorance as I've live on my life without it.
Have you tested this with the 4.04 dev releases? The load_tmpl() hook
changed a little there?
No, I haven't. According to the cgiapp Changes file, it shouldn't
really matter. The only parameters I use in the load_tmpl callback are
the cgiapp instance (see if TT's involved and get the current runmode
and session) and the tmpl parameters (to splice in the messages).
I will be uploading 0.12 shortly (with doc changes).
- Jason
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/[email protected]/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]