如何在html中控制div重叠 [英] how to control div overlapping in html
问题描述
我正在创建一个网页,并且我有两个'div,例如A和B.
现在A的位置是'fixed',它位于页面顶部,但B的位置是'绝对',位于页面中间的某个位置。当它们重叠时,B出现在A之上,但我希望这是另一种方式。我希望A能够超越任何事物,但我不知道该怎么做。
预先感谢您。 :)
使用z-index值将它们相应地调整为图层。
其风格属性:style =z-index:200....
I am creating a webpage, And I have two 'div's, A and B for instance. Now A's position is 'fixed' and it's on top of the page, but B's position is 'absolute' and is somewhere in the middle of the page. When they Overlap, B comes on top of A, But I want this to be the other way around. I want A to come on top of anything, but I don't know how to do that.
please note that changing their positioning is not an option.
Thank You in advance. :)
use z-index value to adjust them accordingly to layer. its a style property: style="z-index:200"....
这篇关于如何在html中控制div重叠的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!