Why div over table
Chris Knadler 2, 2 2 gold badges 24 24 silver badges 32 32 bronze badges. Rickstar Rickstar 5, 20 20 gold badges 52 52 silver badges 74 74 bronze badges.
Add a comment. Active Oldest Votes. Improve this answer. Crowder T. Crowder k gold badges silver badges bronze badges. I'm shocked to find that I ever linked to that site in the first place. Updated to link to the W3C docs, and added example. Justin Carroll Justin Carroll 1, 1 1 gold badge 12 12 silver badges 36 36 bronze badges. Jake Jake 7 7 silver badges 17 17 bronze badges.
Still need z-index depending on where it is in the markup compared to the things it will be on top of. Sign up or log in Sign up using Google. Sign up using Facebook. We're looking at building an app that generates a timeline view for schedules - similar to the TIMELINE view in Outlook where the description for the time line appear immediately above the timeline.
The idea is to use the ID to retreive the specific location on screen and then position the DIV at the horizontal position of the cell and at a vertical position less than the cell. When the table is created, every other row would contain timeline information so that the corresponding labels would be placed in the empty row of cells.
Placing the DIV on top of the time line isn't an option as there is no guarantee that the length of the text in the div would be the same as the timeline. However once I set the position attribute to fixed , the table column come out of the div tag.
Is there any way we can avoid this. May be z-index can help. I tried using that. But it was not working. Valentin Crettaz. I like Any element that is positioned using "fixed" is not in the flow of the document, and thus, it is normal that you see it outside of the containing div.
Try setting the position of the div to "relative" and the oe of the table to "absolute". As you said I have already tried that option and that is working also. Is there any way I can apply the scroll bar to the table with some tds having position:fixed? Thanks in advance Samir. I have purposely changed the "onclick" of the button to "onClick s " as the site was not accepting it. I'm not sure I understand what you want to do. Basically, you'd like the div to only apply to the last two columns after clicking on the button, i.
Is that right? Is that possible.
0コメント