Back Again - I need some smarty help please [Solved]

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
tmeyer45458

Back Again - I need some smarty help please [Solved]

Post by tmeyer45458 »

I'm attempting to use "or" within a smarty tag but can't seem to make it work.  Each time I use the code in bold font, "boo" shows on everypage.  Now, if I omit ["this-page" or "that-page"] then "boo" shows on the about page and "boohoo" shows on the dealers page.  My code is as follows:

{if $page eq "about-us" or "this-page" or "that-page"}
boo
{elseif $page eq "dealers"}
boohoo
{else}
Catch all content
{/if}

How do I "group" pages together using the "or" operator...or any other method for that matter?

I'm simply trying to make it possible to show different content in the sidebar for different pages.  For the most part all is working, but when I try to show the same content on more than one page I run into issues.

Thanks in advance for the help!

Tim
Last edited by tmeyer45458 on Wed Mar 14, 2007 7:30 pm, edited 1 time in total.
tmeyer45458

Re: Back Again - I need some smarty help please [Solved]

Post by tmeyer45458 »

My question was answered at the DP forums.  In case someone has a similar question heres the answer:

{if $page eq "about-us" or $page eq "this-page" or $page eq "that-page"}
Locked

Return to “CMSMS Core”