I want to hide displaying optional items in .tpl file. For instance, DCT got 3 items, First Name, Middle Name Last Name. Middle Name is optional. If user didn't enter any data for Middle Name item then i want to hide displaying middle name when the page is generated. Appricate any help.
Thanks for the suggestions. I tried it using before posting here. it doesn't work because the item is not in the DCR. Any other suggestions. Thanks
I think you need to post a snippet of a DCR where the optional field is not filled in *and* the relevant portion of your PT code.
<iw_if expr='{iw_value name="dcr.name.mname"/} ne "" '> <iw_then> <tr> <td>Middle Name</td> <td><iw_value name='dcr.name.mname'/></td> </tr> </iw_then></iw_if>
<iw_if expr='XX{iw_value name="dcr.name.mname"/} ne "XX"'>