• Archived  

By seGAP - April 3, 2007

Something we noticed in the documentation...

http://www.interactivetools.com/docs/articlemanager2/templates/index.html

shows the templateIf syntax as:

templateIf $placeholder$ eq "Yes"

whereas we think it needs the colon:

templateIf : $placeholder$ eq "Yes"
seGAP

Re: [ross] templateIf syntax

  • Archived  

By seGAP - April 3, 2007

Thanks Ross,

We tested it in an Admin template (we haven't yet upgraded from v2.0), and got an error without the colon.

=====
Error: Closing templateIf tag without opening tag in template content!
=====

As soon as we put the colon in, it works fine.

So do you think this is something dating back to v2.0, or just in Admin?
seGAP

Re: [seGAP] templateIf syntax

  • Archived  

By deniseb - April 4, 2007

Hi seGap,

Thanks for the follow-up!

It looks like you may need to have the colon in the Article Manager admin template files. I would suggest using the colon in both your website template files and your admin template files. :)

Does this help seGap? If you have any further questions please feel free to ask.

Re: [ChetW] templateIf syntax

  • Archived  

By seGAP - May 19, 2007

Chet,

We're now on v2.13 and although we are using the Colon format for templateIf in our Admin templates, we just noticed by accident that if you miss the Colon then you don't get the error that v2.0 used to give, but any code within the templateIf seems to be executed unconditionally.

Are you able to confirm (or disprove) this at your end?

If it does turn out to be true, then the old error message was a better option than the behaviour that we seem to be getting.

Thanks,
seGAP

Re: [seGAP] templateIf syntax

  • Archived  

By deniseb - May 20, 2007

Hi seGAP,

Thanks for the post!

I have been playing with this a little bit and it does look like a templateIf will work with or with out a colon in the admin templates. So far I hav been unable to re-create what you had mentioned. I would suggest the best thing here is to always use a colon in your templateIf's, whether it be on an admin template or a website temaplate. :)

Does this help? If you have any other questions please feel free to ask.