Hi,

If you look at the Getting Started Guide in the section about the
variables that you get in your templates, you'll see instructions on
how to set up a "variable provider". That will let you pass your
access info into all of the templates.

Kevin

On 2/10/06, nederhoed <[EMAIL PROTECTED]> wrote:
>
> Hello again!
>
>
> I've come to know SQLObject, now it's time to enclose my models via TG.
> User login / logout works on a single page using Mochikit, even some
> nice visual effects. I like it!
>
> My next step is a dynamic block with different content, depending on a
> user being logged in or not.
>
> How should I do this?
> My first impression is that it should be part of the master template.
> Can the master template call my login manager class?
>
> access = AccessManager()
> if access.get_user():
>    ...
>
> Somehow, I had rather not create python objects inline in my template.
> I would expect it to be possible to use some 'macro' from another
> template, which questions  on my controller if the user is logged on.
> Like METAL macros in Zope.
>
>
> Suggestions are very welcome, Robert-Reinder
>
> Did I already say I like turbogears and it's underlying techniques? :)
>
> --
>
>


--
Kevin Dangoor
Author of the Zesty News RSS newsreader

email: [EMAIL PROTECTED]
company: http://www.BlazingThings.com
blog: http://www.BlueSkyOnMars.com

Reply via email to