Search code examples
tridiontridion-2011

Adding parameters in Dreamweaver Templates in SDL Tridion 2011 SP1


I learned about Custom parameters and expressions in Dreamweaver MX templates.

So I tried adding them in my DWT TBB, like this.

<!-- TemplateParam name="border" type="number" value="1" -->
@@border@@
<table>
  <tr>
    <td>@@(border)@@</td>
    <td><!-- #TemplateExpr expr="border" --></td>
  </tr>
</table>

But I am getting a blank output without any error.

I want to add variables to my Dreamweaver TBB and get their values. Can anyone suggest if there is any other approach?


Solution

  • Unfortunately Tridion DWTs only share some syntax with the full Dreamweaver templates, so the above syntax will not work.

    There is however a way to set variables, which is well documented here:

    http://www.tridiondeveloper.com/get-and-set-variables-in-dwts