how about
http://127.0.0.1/app/servlet/app/template/UserHome.vm/layout/public
public class Default extends SecureScreen {
public void doBuildTemplate(RunData data, Context context) {
String myLayout = data.getParameters().get("layout")
if( myLayout != null) {
data.getTemplateInfo().setLayoutTemplate("/" + myLayout +".vm");
}
super.doBuildTemplate(data, context);
}
}
obviously this is insecure... so maybe key off the screen name...
you could also base it off the logged in user...
just some thoughts...
----- Original Message -----
From: "Dan E." <[EMAIL PROTECTED]>
To: "Turbine Users List" <[EMAIL PROTECTED]>
Sent: Wednesday, November 21, 2001 4:09 PM
Subject: RE: How are layouts found?
> I agree. Maybe someone else has a better approach.
>
> Dan Eyassu
>
> On Wed, 21 Nov 2001, Scott Merritt wrote:
>
> > Cool, that works great but seems kinda ugly to be putting that big call
in
> > all screens...
> >
> > -----Original Message-----
> > From: Dan E. [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, November 21, 2001 12:36 PM
> > To: Turbine Users List
> > Subject: Re: How are layouts found?
> >
> >
> > Try adding this to the top of each screen(.vm file) that is in a
> > subdirectory:
> > $data.getTemplateInfo().setLayoutTemplate("/<subdirectory>/<screen>.vm")
> >
> > substitute 'subdirectory' and 'screen' appropriately.
> >
> > Dan Eyassu
> >
> > On Wed, 21 Nov 2001, Scott Merritt wrote:
> >
> > > I wrote a small app that has pages for the backoffice portion and the
> > actual
> > > site has it's own public pages. The pages for the backoffice tool
extend
> > > from a secure screen class and the site pages extend off of different
> > > classes.
> > >
> > > My question is... how do I get Turbine to select a template layout
for
> > the
> > > tool pages and a seperate layout for the public site?
> > >
> > > I started putting the two groups of pages (screens) in seperate
> > directories
> > > under the /screens directory but that just led to more confusion.
> > >
> > > Thanks...
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > > For additional commands, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > >
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> >
> > --
> > To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
> >
> >
>
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>