[web] Giving up on DIV layouts

Started by
23 comments, last by Sonnenblume 17 years, 5 months ago
I 100% agree. That's a horrible draft.

Back on topic, the CSS Discuss layouts page is great for getting working layouts.

<hr />
Sander Marechal<small>[Lone Wolves][Hearts for GNOME][E-mail][Forum FAQ]</small>

Advertisement
Everyone one of those can be broken by changing the font size :p.
The biggest advantage to using CSS layouts is the flexibility. For instance, you could completely rearrange the layout by changing the external stylesheet and not the HTML itself. If you have hundreds of pages, or worse, dynamically generated pages, having CSS layouts comes in really handy.

Another example is when you need to serve the same content in different ways (visually impaired / high contrast version, print version, dark version, light version, etc...). At work, i'm currently working on a site that basically gets "resold". Resellers want lighweight theming. This can be done easily by keeping the HTML more or less the same but changing the linked stylesheet for the particular reseller. That way everyone can have their own "theme" but still use the same HTML. Yeah CSS!

Admittedly, it's more of a hassle up front. But i've had to deal with enough FrontPage table-based crappy crap crap to burn me on tables forever. Tables are still good for tabular data, and in very light layouts, but for major layouts, i'm starting to like CSS much more. A few years ago, i wouldn't say that, but now that browsers are starting to catch up i think CSS is the future.
Quote:Original post by Kylotan
Quote:Original post by Beer Hunter
Until CSS provides something sensible for layout, tables are just plain easier in some cases.
Wow, that's quite possibly the worst-explained W3 (draft) spec I've seen, and that's saying something. The use of arbitrary strings is a bit horrific. It's fixing the wrong problem ...
Hehe, OK, granted. In spite of its flaws, though, I think it's a step up from floats if all I want is a three-column layout. Here's hoping that they can re-do it without the suck.
Quote:Original post by leiavoia
The biggest advantage to using CSS layouts is the flexibility. For instance, you could completely rearrange the layout by changing the external stylesheet and not the HTML itself. If you have hundreds of pages, or worse, dynamically generated pages, having CSS layouts comes in really handy.

Another example is when you need to serve the same content in different ways (visually impaired / high contrast version, print version, dark version, light version, etc...). At work, i'm currently working on a site that basically gets "resold". Resellers want lighweight theming. This can be done easily by keeping the HTML more or less the same but changing the linked stylesheet for the particular reseller. That way everyone can have their own "theme" but still use the same HTML. Yeah CSS!

Admittedly, it's more of a hassle up front. But i've had to deal with enough FrontPage table-based crappy crap crap to burn me on tables forever. Tables are still good for tabular data, and in very light layouts, but for major layouts, i'm starting to like CSS much more. A few years ago, i wouldn't say that, but now that browsers are starting to catch up i think CSS is the future.


Pretty much true, but the future isn't today imo, people still use browsers as old as IE4 and making sure your website looks ok is a royal pain in the ....

CSS is a powerful tool but without proper browser support im not really comfortable using it for the layout. (using it for fonts etc isn't as much of a problem since that does work properly with most browsers, and those that doesn't support it will still display the text), ofcourse for more complex layouts you really don't have much choice as tables quickly degenerate into a ugly unreadable mess of <tr .....><td .....>yucky-yucky</td><td>more yuck</td></tr>
[size="1"]I don't suffer from insanity, I'm enjoying every minute of it.
The voices in my head may not be real, but they have some good ideas!
IE4 O_o

I don't even support that on the commercial sites I build. I haven't seen someone using IE4 in years. I support IE5 and 5.5 up to the point that the layout doesn't break in some horrible way (box model hacks) but I let everything else degrade gracefully. I don't even support IE6 fully (usually some visual but non-important gimicks that rely on arbitrary :hovers or complex selectors that are too hard to hack into IE6).

<hr />
Sander Marechal<small>[Lone Wolves][Hearts for GNOME][E-mail][Forum FAQ]</small>

Quote:Original post by Sander
IE4 O_o

I don't even support that on the commercial sites I build. I haven't seen someone using IE4 in years.
I have, but that was with a rather unusual target audience as the majority of the site's users all lived in the middle of nowhere and were using very old computers and software. I'd have to agree with Sander that unless you know you're targetting an unusual audience there's no real need for IE4 support these days.

- Jason Astle-Adams

ok does anybody kno how to make a DIV layout cuz i dont get this thing at all man and i wanna make mi own so that its totally me
What exactly don't you understand about the concept of using divs for your layouts? Do you not understand the idea at all, or is there a specific problem you're experiencing?

- Jason Astle-Adams

Quote:Original post by MartinaJazmineDA
ok does anybody kno how to make a DIV layout cuz i dont get this thing at all man and i wanna make mi own so that its totally me


The concept is easy enough. You put <div></div> around each logical block on your page, then you use CSS style sheets layout the divs over the page. See the CSS discuss layouts page I posted above.

<hr />
Sander Marechal<small>[Lone Wolves][Hearts for GNOME][E-mail][Forum FAQ]</small>

This topic is closed to new replies.

Advertisement