+ -
当前位置:首页 → 问答吧 → CSS IE8表单图片提交按钮移动问题

CSS IE8表单图片提交按钮移动问题

时间:2011-09-10

来源:互联网

用背景background图片做搜索框表单的提交按钮,在IE8浏览器点击会发生向上移动的问题,这样就会把搜索框的背景的border部分给挡住,有点难看,有没有什么解决方法让其在IE8下不发生移动??
CSS代码如下
复制内容到剪贴板
代码:
#search {float:right;margin-top:35px;width:578px;height:66px;background:url(images/search.gif);}
#search input.submit {float:left;width:130px;height:34px;background:url(images/search.gif) no-repeat -441px -65px;border:none;margin-top:27px;cursor:pointer;outline:none;}
#search input.search {float:left;width:407px;height:28px;line-height:30px;padding:0px;margin:30px 0 0 33px;border:none;}
form表单
复制内容到剪贴板
代码:
    <div id="search">
        <form method="get" id="searchform" action="">            
        <input type="text" value="" class="search" name="s" id="s" size="20" />
        <input type="submit" id="submit" value="" class="submit" />
    </form>        
    </div>
a.jpg (7.01 KB)
未点击前
2011-9-10 23:04

b.jpg (11.23 KB)
点击时
2011-9-10 23:04


[ 本帖最后由 telunsu 于 2011-9-10 23:04 编辑 ]

作者: telunsu   发布时间: 2011-09-10

最好能发上来代码,你说的别人估计没见过,最好把出现这个问题的源代码发上来

作者: wyysf   发布时间: 2011-09-10

代码图片都上传了。麻烦帮我看下。

作者: telunsu   发布时间: 2011-09-10

这个问题,说实话,还没遇到过。

作者: kesin   发布时间: 2011-09-10