Why does adding float:left to my css make my link unclickable?

前端 未结 4 2236
清歌不尽
清歌不尽 2021-02-12 01:31

I have a view with a section defined thus:

<%=ViewData.Model.Body %>

4条回答
  •  一整个雨季
    2021-02-12 02:19

    The usual reason is that there's a transparent layer on top. It's normally caused when a box is wider than you think and has a transparent border/padding. Use CSS to apply a temporary border to all items and you'll check whether it's the case.

    Update #1

    div, span, p{
        border: 1px solid red;
    }
    

    Update #2

    I can see that #QuestionEditLink and #QuestionHistoryLink are floating. That means that they no longer use space in the page flow. So when you display #AskingUser next it starts at the same point and, being the last one on the page, it gets displayed on top of the two other boxes.

    Your layout appears to be fully vertical. I presume you don't need any float: left at all.

    BTW, you have lots of duplicate IDs.

提交回复
热议问题