|
Posted by Neredbojias on 01/14/06 23:47
With neither quill nor qualm, Els quothed:
> Jukka K. Korpela wrote:
>
> > Els <els.aNOSPAM@tiscali.nl> wrote:
> >
> >> If you just enclose your entire page in one div, it might save you
> >> some code, depending on how many loose images you have in it.
> >
> > You save more code by using HTML 4.01 Transitional, which allows "loose"
> > content inside body and does not require all end tags.
> >
> > If you wish to comply with a Strict DOCTYPE, then it's rather pointless to
> > use <body><div>...</div></body>, since the _idea_ in Strict is to put text
> > and inline markup inside _suitable_ blocks. If you don't care about the idea,
> > you could use Transitional, which does not require the pointless
> > <div> and </div> tags.
>
> You're probably right about the Strict rules, but I think that having
> loose images in a page isn't quite the same as switching to
> Transitional altogether.
> I always have my pages in a div, simply because I like to have the
> option to add a border, a margin. I always have <body><div
> id="container">....</div></body>
> Often I give that container a left and right margin and a border
> colour, or even a shadow effect.
>
> And if I then have some decorative images floated left and right
> within the content, I really don't see the problem if there isn't a
> <div></div> around them. I think the rule that images and inline
> content should be inside suitable blocks, wasn't invented for floating
> decorative images, but for semantics. Decorative images aren't
> semantic by definition, but because of the <img> element, they are
> caught in the rule together with text that should be in paragraphs and
> inline images. I prefer to look at the whole of an idea, instead of
> scrutinously applying rigid rules without thinking about the reasons
> for those rules. Unless there is a compatibility or accessibility
> reason for putting decorative images in divs, I don't see the point,
> and I find switching to Transitional an over the top measure to allow
> loose images. Really, what's worse in your opinion: add a possibly
> superfluous div, or change to a doctype that allows a bunch of
> deprecated code?
I have (a few) pages where I don't use a doctype at all. Why? Simply
because they work better, -tested in IE, Mozilla&Firefox, and Opera. Of
course this is basically just "appealing to" quirks mode, but you and I
have already discussed issues relating to the vertical centering of
small content.
Surprisingly (at least to me) is that with some markup Mozilla and Opera
work better than IE even under this "quirks mode" auspices.
--
Neredbojias
Contrary to popular belief, it is believable.
Navigation:
[Reply to this message]
|