This is a discussion on "table-like structure" within the Web Page Design section. This forum, and the thread "table-like structure are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
table-like structure
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
|||
|
table-like structure
hi all
i'm using css and divs to create a table-like effect, as such: <div style="float: left; width: 50%; clear: both">Company Name</div> <div style="float: right; width: 50%; clear: both">Acme</div> <div style="float: left; width: 50%; clear: both">Email</div> <div style="float: right; width: 50%; clear: both">info@acme.com</div> all well and good, until i get an over-long company name, which wraps the text onto the next line, so that the wrapped text lines up with the "Email" header. i don't mind that the text wraps, but i'd like the next "row" to be pushed down by the wrapped text, if possible any suggestions? TIA |
|
|
|
|||
|
Re: table-like structure
I'm not being funny here, but the content/structure suggests to me that you should actually use an HTML table. (And I'm a CSS bloke!).
|
|
|||
|
Re: table-like structure
thanks prototypecoding, i'm aware that this is tabular data, and i'd be forgiven for using a table
dave |
|
|||
|
Re: table-like structure
Hmmm, this seems to work pretty well in IE and FF:
<div style="float: left; width: 49%;">Company Name</div> <div style="float: right; width: 49%;">Acme Acme Acme Acme Acme Acme</div> <div style="width:100%; clear: both"></div> <div style="float: left; width: 49%;">Email</div> <div style="float: right; width: 49%;">EMAIL REMOVED - Send PM to This User Instead</div> |
|
||||
|
Re: table-like structure
Quote:
If you did it this way, sure it would be an acheivement but it would be wrong. It would be just as wrong as using tables for layout. The problem arrises when tags are used to do jobs they were never meant to do. Tables for lauout is wrong and CSS controlled div tags for displaying tabular data is wrong. Hope this clears things up.
Last Blog Entry: Annoying people.... (Jan 16th, 2008)
|
![]() |
| Tags |
| tablelike, structure |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Website Structure | marSoul | Website Planning | 4 | Oct 11th, 2007 19:31 |
| Frame structure | WLQ | JavaScript Forum | 1 | Oct 8th, 2007 09:56 |
| blog structure | alexgeek | PHP Forum | 25 | Aug 26th, 2007 01:23 |
| Request opinion on a database table structure | doowop | Databases | 0 | Sep 23rd, 2005 13:22 |