Page 1 of 1
Tableless?
Posted: Mon Feb 09, 2009 4:56 pm
by Moviews
I looked at the source code for v1.1. Will be tableless? (Currently not.)
Re: Tableless?
Posted: Mon Feb 09, 2009 7:00 pm
by Daniel
which parts are you complkaning about?
the layout is not a made from tables.
there is also nothing wrong with using tables they are all part of the html
Re: Tableless?
Posted: Mon Feb 09, 2009 8:08 pm
by Moviews
That's right. There is no problem. Table is a html selector. Just I think this isn't "trend". For example in catalog\view\template\common\home.tpl see
Re: Tableless?
Posted: Sun Feb 15, 2009 1:21 am
by Daniel
If firefox and IE supported full CSS2 I would be fine using divs but they don't.
What happens if you don't set a height is they start going out of wack and not dropping to the next line. If you set a height and someone enters a long tilte the information falls out of the bottom of the div box.
The list page is fine because its tubular data.
Re: Tableless?
Posted: Tue Feb 17, 2009 9:03 am
by nde
I think the current way using a table for the product grid is perfectly ok. Some will argue that semantically it's a list and not tabular data.
However, there will be problems if a product title is a little bit too long (see illustration below). I know, chances for this to happen aren't very high, but you can easily fix it.
http://i40.tinypic.com/kdlsw6_th.png[/img]
http://i42.tinypic.com/qoamuf_th.png[/img]
If you give
table-layout:fixed to the CSS of the table, it will stick to the width you specified via CSS (also works with tables that are set to width=100%).
If you add
overflow:hidden, the long title won't flow out of the table
Code: Select all
.list {
table-layout:fixed;
}
.list td {
overflow:hidden
}
the result:
http://i41.tinypic.com/2a68qog_th.png[/img]
Re: Tableless?
Posted: Tue Feb 17, 2009 9:09 am
by fido-x
Daniel wrote:
What happens if you don't set a height is they start going out of wack and not dropping to the next line. If you set a height and someone enters a long tilte the information falls out of the bottom of the div box.
A way around this is to add --
before closing the main div.
Fido-X.