Karoly Negyesi wrote:
Hi,
I would like to ask everyone not to use literal <table> <tr> and <td> tags ongoing. We have a theme('table').
Trivial example: zebra. Instead of striping everything separately we can do it centrally.
theme('table') is a really interesting conundrum. On pages that utilize tables, they are great for the programmer, and actually really hard on a designer. As we're moving toward templatizing the theme functions of Drupal, there turns out to be nothing to put into a .tpl.php for something that is, ultimately, just a table. On the other hand, not using theme('table') has the problem of leading to inconsistency. Right now you can do quite a bit by theming all of your tables...but no one ever (to my knowledge) actually overrides theme('table'), and most of that theming is done via CSS. I think what this really means is that theme('table') needs to be expanded in such a way that we can do named tables that will allow us to invoke individual templates in the manner of node.tpl.php. Something like table-forum_overview.tpl.php maybe. I've done a lot of back-and-forth with myself on this one, because there are arguments on either side of the fence that are really compelling. I'm curious to hear other people's thoughts on this one.