Can I use CSS to align a
inside a ?
Thanks in Advance.
Thanks in Advance.
1 Reply
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jiteendra SampathiraoPosted Jul 11, 2011, 1:09 AM
Using a div instide a td is not worse than any other way of using tables for layout. (Some people never use tables for layout, and I'm one of them.)
If you use a div in a td you will however get in a situation where it might be hard to predict how the elements will be sized. The default for a div is to determine it's width from it's parent, and the default for a table cell is to determine it's size depending on the size of it's content.
The rules for how a div should be sized is well defined in the standards, but the rules for how a td should be sized is not as well defined, so different browsers use slightly different algorithms.
Source: stackoverflow..
Hope it help you....