|
Ian -
it did make it and you got the following reply I believe:
-----Original Message----- From: Stephen Milligan [mailto:[EMAIL PROTECTED] Sent: 05 April 2004 21:21 To: [EMAIL PROTECTED] Subject: RE: [ cf-dev ] displaying images 4 across in a table...
The logic to do it works something like this: <!--- The number of columns required ---> <cfset cols = 4> <!--- The number of loop iterations to run through ---> <cfset records = 50> <!--- The number of empty cells to put in the final row ---> <cfset padding = records mod cols> <!--- Open the table tag and first row ---> <table> <tr> <!--- Loop over the recordset, array or whatever ---> <cfloop from="1" to="#records#" index="i"> <!--- Output the image tag inside the table cell ---> <td>#i#</td> <!--- Check if i is exactly divisible by the number of columns. If so, close the row and start a new one ---> <cfif i mod cols EQ 0> </tr> <tr> </cfif> </cfloop> <!--- Create the padding cells ---> <cfloop from="1" to="#padding#" index="i"> <td> </td> </cfloop> <!--- Close out the table ---> </tr> </table> HTH Spike _______________________________________________________ * Regards, Westminster City
Council - Web Support ( 0870 906 7482
======================================================= This message contains information that may be privileged or confidential and is the property of the Cap Gemini Ernst & Young Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorised to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. ======================================================= |
- [ cf-dev ] displaying images 4 across in a table... Ian Westbrook \(FDM\)
- RE: [ cf-dev ] displaying images 4 across in a ... Stephen Milligan
- Lovelock, Richard J
