[ic] using if clause with area in template to adjust image

Paul Jordan interchange-users@icdevgroup.org
Sat Feb 22 12:11:01 2003


> On Sat, 22 Feb 2003 09:45:47 +0200
> "Rene Hertell" <interchange-users@hertell.com> wrote:
>
> > > On the devgroup site, using google, and searching for "if page is
> > > index" the
> > > first hit is:
> > >
> > > http://www.icdevgroup.org/archive/interchange-users/2002/msg00719.html
> > >
> >
> > The @@MV_PAGE@@ is not used anymore, and should nowadays be
> replaced with
> > [var MV_PAGE 1]
>
> They are basically the same thing, the only difference is that @@MV_PAGE@@
> wouldn't interpolated within a variable, such as the region files provide.
> So don't deprecate @@MV_PAGE@@, it is faster in a page.
>
> Bye
>        Racke

Yes, and as for this thread, I would suggest Dan Brownings idea, which is a
follow up to Kevins post. If you take the hint from [tmp page_title], you
can reduce alot of things into GO/NO-GO tests, instead of comparisons.

[tmp doindex]1[/tmp]   <-- in header

----------------

  [if scratch doindex]
       <img alt="Home" border="0" src="__THEME_IMG_DIR__home_tan.png"></a>
     [else]
       <img alt="Home" border="0" src="__THEME_IMG_DIR__home_green.png"></a>
     [/else]
     [/if]


>From there, you realize the header (if that is what it is called) is the key
to doing page specific things in the templates, and can be very powerful for
altering the look, page to page, without needing another template, and still
be efficient.

Paul