KirstyH wrote:
> I don't understand this. I thought that "relative" meant "relative to
> the natural position of the element in the document flow". So why does
> it make sense to position something relatively without specifying a
> position?
If you position an element relatively or absolutely it becomes what I
think the CSS specs call a "positioned element". Once you have a
positioned element, you can position absolute elements within it.
Example 1:
<body>
<div>
<span style="position:absolute;top:3px;left:8px;">x</span>
</div>
</body>
Example 2:
<body>
<div style="position:relative">
<span style="position:absolute;top:3px;left:8px;">x</span>
</div>
</body>
In example 1, the letter 'x' is positioned 3px down and 8px along from the
top left corner of <body>.
In example 2, the letter 'x' is positioned 3px down and 8px along from the
top left corner of the <div>.
--
Toby A Inkster BSc (Hons) ARCS
Contact Me -
http://www.goddamn.co.uk/tobyink/?page=132