Matt BurelloMatthew Burello
 
 
How to Display Coldfusion Output in Multiple Columns

To display CFOUTPUT data in multiple table rows is easy, but when you want to display data in multiple table columns the task can be daunting. The following code shows the most efficient way to accomplish the display of CFOUTPUT data in multiple table columns. Simple replace the words"Your_Query" with your query name, "Your_Data" with whatever data you want to display, and the number "3" following the word "MOD" to however many columns you want to display.

<TABLE>
     <TR>

     <CFOUTPUT QUERY="Your_Query">
          <TD>#Your_Data#</TD>
          <CFIF Your_Query.CurrentRow MOD 3 IS 0>
               </TR>
               <TR></TR>

          </CFIF>
     </CFOUTPUT>
</TABLE>

Latest Innovations