/#keyword/
id名为keyword的input框(搜索框)添加背景图片

#keyword::-webkit-input-placeholder {
    color: transparent;
    text-indent: -9999px;
    background: transparent url(../img/google_custom_search_watermark.gif) no-repeat 10% center;
}
#keyword::-moz-placeholder {
    /* Firefox 19+ */
    color: transparent;
    text-indent: -9999px;
    background: #fff url(../img/google_custom_search_watermark.gif) no-repeat 10% center;
}
#keyword:-moz-placeholder {
    /* Firefox 18- */
    color: transparent;
    text-indent: -9999px;
    background: transparent url(../img/google_custom_search_watermark.gif) no-repeat 10% center;
}
#keyword:-ms-input-placeholder {
    /* IE 10- */
    color: transparent;
    text-indent: -9999px;
    background: transparent url(../img/google_custom_search_watermark.gif) no-repeat 10% center;
}

Linda0821
62 声望4 粉丝