I have a structure like this
<div id="first">
<div id="second">
<div id="third">
<div id="fourth">
text
</div>
<div id="fourth">
text2
</div>
</div>
Some other stuff...
</div>
</div
Here’s the css for it at the moment:
#first {
width:960;
}
#second {
position:relative;
}
#third {
position:relative;
top:0;
right:0;
}
#forth {
position:relative;
top:0;
left:0;
}
Now I would like from the fourth items to stay in a row and from the third item to stay on the right side of the second div. The second div also has a width 960 like the first one.
What’s the problem with this? why it isn’t working?
Edited and should work(untested):
And the style:
ID’s should be used for elements that will only be used once. Classes should be used for elements that can/will be used multiple times.