2

I have the following setup on 2 div tags:

<div id='div1' style='position: absolute; z-index: 2;'>

</div>
<div id='div2' style='z-index: 999;'>

</div>

The problem is tha the second div tag contains a link which is not clickable, meaning that the intiail div tag (or DIV1) is on top of it preventing me from being able to click div2.

I can't find a fix for this after messing with it for some time...

Ben
  • 58,238
  • 105
  • 295
  • 471

1 Answers1

7

The CSS z-index property only works on positioned elements. So you will need to, for example, assign position: relative; to your div2.

TNi
  • 14,808
  • 2
  • 21
  • 20