Creating Output Tables with HTML's <TABLE> Tag

Using HTML's standard table tags to organize your query output can make for some very sleek page designs, but it can also be one of the most frustrating tasks you'll ever complete with ColdFusion. HTML tables can be taxing enough on their own—one missed </TD> tag can keep your table from displaying at all. Add a repeating <CFOUTPUT> section, and you have a potentially nail-biting experience.

For those reasons, it's a good idea to use extensive comments and indentations in your code to help organize table rows and columns. If you take the time to organize table code carefully so that it illustrates the flow of your table, you'll save many troubleshooting hours later.

Tip

ColdFusion Studio users can ...

Get Sams Teach Yourself ColdFusion® in 21 Days now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.