My question is almost stupid because I think I know the answer but I wanna be sure. Does it exist a mechanism to be able to put a tag at a specific location. I mean, I can set the coordinates X and Y of a tag. Maybe this specific tag should be placed in a special parent tag?
Do you know an another way to do this?
An example should be something like this :
<html>
<body>
<div id="container" >
<img src="..." x="40" y="0" />
<img src="..." x=70" y ="10"/>
....
</div>
....
Many thanks for you attention,
Bat
Well, if you want an element to be placed at a specific location on the page, you can give it
position: absolutein CSS, together with it’s position relative to the last parent element that has a position value ofrelativeorabsolute.For instance, with this HTML
Can be placed 100px off the top and left of the page with this CSS
Given your example, no, not entirely. You can use the
styleattribute for the same effect though:Assuming
#squarehasposition: absoluteapplied to it from a stylesheet already. It’s best however if you incorporated this into a stylesheet, since content and presentation should be separate.