Text indent is not working in ie7

前端 未结 14 1793
礼貌的吻别
礼貌的吻别 2021-01-31 09:43

I am working on a website and on the top navigation bar there is a search box, I applied the following css on the search submit button

#submit {
   background:          


        
14条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-31 10:32

    Here is some CSS I'm using that works for me in IE and doesn't rely on text-indent

    .sprite {
        width:100%;
        height:0px;
        padding-top:38px;
        overflow:hidden;
        background-repeat:no-repeat;
        position:relative;
        float:left;
        display:block;
        font-size:0px;
        line-height:0px;
    }
    .sprite.twitter {
        background-image:url(/images/social/twitter-sprite.png);
        margin-top:8px;
        background-position: 4px 0px;
    }
    #social-links a:hover .sprite.twitter {
        background-position: 4px -38px;
    }
    

提交回复
热议问题