View Single Post
  #1  
Old 07-11-2010, 04:42 PM
 
Sisom Sisom is offline
 

eXpert
  
Join Date: Sep 2006
Posts: 310
 

Default Why are they still using tables for layout?

I've just been fiddling with the X-Cart installation that I'm customising for a client, and I decided to try displaying the Featured Products in two column mode. Suddenly, all the changes I had implemented on the one column version were lost, and then I looked in Firebug and my heart sank: tables.

Not only tables, but the craziest implementation I have ever seen.

Code:
<tr class="first product-name-row"> <td class="first product-cell"> <div class="image"> <a href="product.php?productid=17515&cat=0&page=0&featured=Y"><img src="http://www.mrdtrading.co.uk/store/images/T/kart2small.jpg" width="125" height="79" alt="Red Rooster Go Kart" /></a> </div> </td> <td class="highlight last product-cell"> <div class="image"> <a href="product.php?productid=17518&cat=0&page=0&featured=Y"><img src="http://www.mrdtrading.co.uk/store/images/T/xctD748.tmp.png" width="125" height="125" alt="Rugged Racer Mini 101" /></a> </div>

So the table spans both columns, and then you have two <td> elements, one for the first product, one for the second. And repeat, all the way down the product description...

I may not have time to completely implement it with this client, but with my next job, I think I am going to completely redo this mess, and make it use CSS properly, i.e. no tables for layout. Perhaps I can get Qualiteam to hire me as their chief CSS designer! (Or rather, ONLY CSS designer, as they don't seem to understand how it works...)


I also keep seeing

Code:
<br /> <br />

and content which is only surrounded by div tags, no paragraph tags, hence their unnecessary use of the <br /> tags. How can you use CSS when you have something like:

Code:
<div class="whatdoescssmean"> A load of text that isn't in a paragraph. <br /> How do you change the bottom margin on the line above? Can't do it. </div>
__________________
X-Cart Gold Version 4.3.2
Reply With Quote