Closing </td>,</tr> never used to be req'd (in w3c spec) ;p Haven't checked lately, tho.
-----Original Message----- From: Bobby Hartsfield [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 16, 2007 5:56 PM To: CF-Talk Subject: RE: cfloop output into columns - help As long as you only had an odd number of records returned, then you'd be ok, else you would not have a closing </tr> on the last row. -----Original Message----- From: Dave Francis [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 16, 2007 7:02 PM To: CF-Talk Subject: RE: cfloop output into columns - help Don't know if you've worked this out yet, but here's a quick way <cfoutput query="q1"> <cfif currentRow mod 2> <tr> <td>#q1.column1#</td> <td>#q1.column2#</td> <cfelse> <td style="padding-left:60px;">#q1.column1#</td> <td>#q1.column2#</td> </tr> </cfif> </cfoutput> -----Original Message----- From: Christopher Chin [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 16, 2007 1:55 PM To: CF-Talk Subject: cfloop output into columns - help Ok..this seemed easy at first..now I'm a bit ticked that I can't figure this out. I'm sure you CF mavens out there have come across this already; I'd appreciate your insight. :) I would like to output my query into a 2 column table; reading left to right. Example: 1 2 3 4 5 6 What I'm getting with my code is: 1 2 2 3 3 4 Here's my code: <cfquery name="blah" datasource="employees"> select * from employees where fname like 'John%' order by fname, lname </cfquery> <cfoutput> <table border="1"> <cfset counter = 0> <cfloop query="blah"> <tr> <td>#blah.fname# #blah.lname#</td> <td>#blah.currentRow#</td> <td>#blah.fname[currentRow+1]# #blah.lname[currentRow+1]#</td> <td>#blah.currentRow+1#</td> </tr> <cfset counter = counter+1> <cfset blah.currentrow = blah.currentRow+counter> </cfloop> </table> </cfoutput> Anyone know how I can work this out to the output that I'd want? How do I also not show the the 2nd <td> if it's not populated (an odd # recordset)> Thanks in advance Chris ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Upgrade to Adobe ColdFusion MX7 Experience Flex 2 & MX7 integration & create powerful cross-platform RIAs http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJQ Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:278385 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4