By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 1,686 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

Tables to Divs

P: 5
I've tried to do this many times, but had no success. How would I convert this into Divs?

Expand|Select|Wrap|Line Numbers
  1. <div align="center">
  2. <table border="0" cellpadding="0" cellspacing="0" width="747">
  3.     <tr>
  4.         <td width="747" colspan="3">TOP</td>
  5.     </tr>
  6.     <tr>
  7.         <td width="426">LEFT</td>
  8.         <td width="7">CENTER</td>
  9.         <td width="314">RIGHT</td>
  10.     </tr>
  11.     <tr>
  12.         <td width="747" colspan="3">BOTTOM</td>
  13.     </tr>
  14. </table>
  15. </div>
I tried it but my main problem was that when LEFT and RIGHT expand vertically due to content, BOTTOM was overlapped. It didn't move down.

CENTER Can be avoided with margin I'm guessing. It's just there to keep the LEFT and RIGHT columns apart 7px.

Oct 26 '06 #1
Share this Question
Share on Google+
1 Reply

Expert 5K+
P: 7,435
The thing is you can't be thinking tables while trying to create a page using divs. You are trying to recreate a table using divs as boxes and that's not how it works. If your information is data, then it needs to be in a table. I assume it's not data so quit trying to imitate one. That's not what divs are for. Divs help with html structure and that is all. Not layout, though, of course, it can be used for that.
Oct 26 '06 #2

Post your reply

Sign in to post your reply or Sign up for a free account.