when div with absolute position is added cannot click on links

前端 未结 8 1415
情歌与酒
情歌与酒 2021-01-01 10:37

I have menu on a page and div that is absolute positioned. The problem is that when this div is on a page, then I cannot click on any links in menu items.

When I re

相关标签:
8条回答
  • 2021-01-01 11:04

    Add a z-index:-1; This will allow the links to be clicked. As The Div is absolutely positioned over the links and hence it is not allowing clickability.

     #left_border {
        background-image: url(http://tax.allfaces.lv/templates/tax/images/ena.png);
        background-position: 0 0;
        background-repeat: no-repeat;
        width: 1094px;
        background-size: 100% auto;
        position: absolute;
        height: 850px;
        left: -51px;
       top: 0px;
        z-index:-1;
    }  
    

    Here is the Working Solution for the same.

    Hope this Helps.

    0 讨论(0)
  • 2021-01-01 11:04

    Your problem is actually with #left_border covering the links as overlay. limit it's width.. e.g.

    #left_border{
      width:50px;
    }
    
    0 讨论(0)
提交回复
热议问题