[Pmwiki-users] Re: Re: Setting Sidebar to ThisGroup:SideBar
Stefan Candea
stefan
Thu Feb 12 15:06:40 CST 2004
> > Note that one can also do:
> >
> > $PageLayoutFmt['wikileft'] =
> > array('wiki:$Group.SideBar','wiki:Main.SideBar');
> >
> > which displays both Group.SideBar and Main.SideBar in the left panel
> > (if they exist).
>
> That's good to know.
As it makes a lot of sense to have left bar group specific, I believe
that right bar should actually be *page specific*, for specific links
specific to the details of the page (e.g. SeeAlso links quick to view and
consistently in the same place - that is one example) This would make it
more dynamic.
>
> > > What do people think about this (default?) behaviour:
> > > If the page '$Group.SideBarLeft' exists, => left sidebar,
> > > otherwise, if 'Main.SideBarLeft' exists => left sidebar
> > > If the page '$Group.SideBarRight' exists, => right sidebar
> > > otherwise, if 'Main.SideBarRight' exist => right sidebar
> >
> > Well, this is easy enough to do:
> >
> > $PageLayoutFmt['wikileft'] = 'wiki:$Group.SideBarLeft
> Main.SideBarLeft';
> > $PageLayoutFmt['wikiright'] = 'wiki:$Group.SideBarRight
> Main.SideBarRight';
> >
> > However, I chose "SideBar" over "SideBarLeft" and/or "SideBarRight"
> to
> > keep the page name associated more with its function/purpose rather
> > than where it appears in the layout.
>
> Hmm... good point.
>
> > Also, keep in mind that with the current layout code, a table cell
> > and/or div would be generated for the wikiright cell even if neither
> of
> > the *.SideBarRight pages exist, and this might not be desirable.
>
Would this actually work better for page specific quick links?
> Actually, that's what I *didn't* want :-( Isn't there a function that
> can
> tell if a page exists which you can use, like this?
>
> if(!PageExists("$Group.SideBarLeft", "Main.SideBarLeft"))
> $PageLayoutFmt['wiki...'] = '';
>
> /Christian
>
> --
> Christian Ridderstr?m
> http://www.md.kth.se/~chr
Stefan.
More information about the pmwiki-users
mailing list