这个边界流过什么
JsFiddle Link
I have two divs overlapping with borders on both. When I set the z-index on one higher then the other shouldn't the border also be blocked by the higher z-index div?
Is there anything I can do to accomplish this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
您需要将背景颜色设置为:
更新的小提琴
You need to set the background color to something:
Updated fiddle
它们目前是透明的。添加背景颜色。
They're currently transparent. Add a background colour.
我在拖放排序环境中的表行上遇到了同样的问题。将背景设置为特定颜色(style =“background-color:White”),它将覆盖它。如果您不设置颜色,它会假定没有背景,只绘制其后面的内容(当它不重叠时,就什么都没有,所以当它实际上是空的时,它看起来像一个纯色背景)。
I had the same problem with table rows in a drag-and-drop sort environment. Set the background to a specific color (style="background-color:White") and it will cover it up. If you don't set a color, it assumes no background and just draws what is behind it (when it's not overlapping, that's nothing, so it looks like a solid background when really it's empty).
设置明确的
背景颜色
Set an explicit
background-color