1 reply [Last post]
Manchester, UK
Last seen: 18 years 38 weeks ago
Manchester, UK
Joined: 2004-09-06
Posts: 3
Points: 0

I use a few empty DIVs for positioning images on screen, and I've noticed oddities:-

If I use:

<div id="content" />

instead of:

<div id="content">

Firefox and IE6 seem to struggle to agree on how it should look. Has anyone else noticed this?

Hugo's picture
Last seen: 8 years 21 weeks ago
Joined: 2004-06-06
Posts: 15668
Points: 2806

Strange DIV quirk

Well for a start the first example isn't how you close a div the /> is just for old tags that were left open such as <img> <br> <meta> which in xhtml you would be required to close with the /> so it probably would cause a conflict of some description but can't say I've ever tried it!


Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me