OverlappingAndZIndex

  • Embedded Gallery2 is not available.
  • Embedded Gallery2 is not available.

There seems to be some confusion about how to get one element to appear on top of another. Do you add z-index: 1 or z-index: 1000? Why do some items overlap others, no matter how high the z-index value goes? This page hopes to clear this up.

There's three different things that impact how elements overlap each other: stacking contexts, source order, and painting order. The most obvious issues come up when dealing with stacking contexts. But knowing the other two will help you figure out the more esoteric gotchas.

http://css-discuss.incutio.com/?page=OverlappingAndZIndex