[albatross-users] context locals question
Brian Brown
rbb at techgame.net
Thu Oct 24 13:59:20 EST 2002
Quoting Andrew McNamara <andrewm at object-craft.com.au>:
> > Let me first say that I absolutely love this toolkit... after hanging
> >on with Zope for years, and seeing it get more and more complex and
> >unmanageable, this is just what the doctor ordered.
> >
> >Anyway... I am using a couple of variables that I am putting into
> >ctx.locals, each one is a dictionary that I use for menu structures on
> >the web site. One is a menu that stays the same and one is a menu that I
> >want to be context dependent. The problem seems to be that if I don't
> >explicitly set this dict in every page module, it goes reverts back to
> >the empty dict that I first initialized. What I have tried to do is
> >create a get and set method at the context level, but this doesn't
> >always seem to work. Is there some other place I should be trying to
> >keep track of a value like this context dependent menu?
>
> Are you calling ctx.add_session_vars( ... ) for the variables in question?
No, I was not...but I tried that late last night and it works wonderfully.
>
> Which context mixin are you using?
>
SessionAppContext
Thanks!
> --
> Andrew McNamara, Senior Developer, Object Craft
> http://www.object-craft.com.au/
>
--
Brian Brown
TechGame Networks, LLC.
Technology is a Game;
Shouldn't you be winning?
More information about the Albatross-users
mailing list