i am try to get a div to floating over table so it will be ontop of all the txt?
+2
A:
Check out z-index (and possibly absolute positioning, although there are other ways to get things to overlap).
T.J. Crowder
2009-12-23 23:02:30
A:
Hi
<div id="floatme">Float this over the text</div>
<style>
#floatme{
position: absolute;
top: XXpx;
left: XXpx;
}
</style>
Just change the top and left variables.
Jake
2009-12-23 23:03:44
Still need `z-index` depending on where it is in the markup compared to the things it will be on top of.
T.J. Crowder
2009-12-23 23:04:28
A:
I would wrap the table in a "positioned" div. I set the div to position:relative
so that it won't interrupt the flow of the rest of the documents contents.
<div style="position: relative">
<table style="width: 500px;">
<tr>
<td>Table Text</td>
</tr>
</table>
<div style="position: absolute; top: 0; left: 0; width: 500px; background: green;">
I am on TOP of the table!
</div>
</div>
jessegavin
2009-12-24 00:44:35
A:
I agree with TJ - z-index is the way to go - using javascript and css/html will allow you to hide/show this "magic floating box" above the table.
Nascent_Notes
2009-12-28 12:12:47