0 Replies Latest reply on Nov 29, 2007 1:09 PM by sankalpah

    empty tag should not be displayed

    sankalpah Level 1
      Hi

      I have this tag which dispalys green tab around it's contents.



      <cfif NOT ThisTag.HasEndTag>
      Page Header, custom tag error.
      <cfexit>

      </cfif>

      <cfswitch expression="#ThisTag.ExecutionMode#">

      <cfcase value="start">

      <table border="0" cellpadding="0" cellspacing="0" style="font-size:10px; color:#88ab2e; font-family:Verdana, Arial, Helvetica, sans-serif; text-decoration:bold;" >
      <tr valign=bottom>
      <td valign=bottom style="width:10px;" width="10px" colspan=2><img src="/images/ETFBoxTagImgs/topTab2-l-10.gif" /></td>
      <!---<td bgcolor="#88ab2e" height="6px" style="width:99%;border-bottom:7px solid #FFFFFF; bgcolor:#88ab2e;"></td>--->
      <td rowspan=2 style="line-height:19px;" align=center><img src="/images/ETFBoxTagImgs/1pixilspacer.gif" width="100%" height="1" border="0" style="font-size:11px;background-color:#88ab2e;vertical-align:bottom;text-decoration:bold ;"/></cfcase>


      <cfcase value="end">


      </td>
      <td valign=bottom align=right style="width:10px" width="10px" colspan=2> <img src="/images/ETFBoxTagImgs/topTab2-r-10.gif" /></td>
      </tr>
      <tr >
      <td valign=top style="border-left:1px solid #88ab2e;"><img src="/images/ETFBoxTagImgs/1pixilspacer.gif" width="1" height="10" /></td>
      <td></td>

      <td></td>
      <td valign=top style="border-right:1px solid #88ab2e;"><img src="/images/ETFBoxTagImgs/1pixilspacer.gif" width="1" height="10" /></td>
      </tr>


      </table>
      </cfcase>
      </cfswitch>





      I WANT THIS TAG TO NOT GET DISPLAYED WHEN IT DOESNOT HAVE ANY CONTENT. RIGHT NOW BLANK GREEN BOX GETS DISPLAYED IN CODE BELOW

      <cfmodule template="../tags/ETF_Tab.cfm">
      <cfloop from="1" to="#ArrayLen(prz)#" index="i">

      <div id=#prz #_#cGroup# style="display:<cfif prz eq 'Prices'>block<cfelse>none</cfif>;">
      <cfif prz neq 'Yy'>
      <a href="index.cfm?cat=220&cGroup=<cfif cGroup eq 'MUNI'>ETF<cfelse>INDEX</cfif>&showit=#prz
      #&LN=#LN#" class="ETFTab" style="text-decoration:none;">
       Equity ETFs 
      </a>
      <cfelse>empty<cfbreak>
      </cfif>
      </div>

      </cfloop>
      </cfmodule>


      HOW CAN I USE FLOW CONTROL TAGS OR ANY OTHER METHOD SO THAT NO HTML NO GREEN BOX IS DISPLAYED WHEN THERE IS NO TEXT INSIDE TAG.

      I DON'T WANT TO SWITHCH(that's programming requirement) CFLOOP & CFMODULE IN ABOVE CODE.

      THANK YOU