Categories > TinyButStrong general >

conditional includes

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: gmak
Date: 2004-02-17
Time: 16:29

conditional includes

Is there a way to do conditional include statements?

What I'd like to do is check a value and then based on that value include a specific sub-template, but I can't seem to get the syntax working.

Any suggestions?
By: Skrol29
Date: 2004-02-17
Time: 16:53

Re: conditional includes

Hi,

The more simple way is to store the templeate name into a variable and then :
  [var.sub_template;file=[val]]

Note: this will include the sub-template at the Show() method. To have it on the LoadTemplate() methode, use :
  [tbs_include.onload;file=[var.sub_template]]