ie6 失真问题

所属分类: 网页制作 / HTML/Xhtml 阅读数: 1930
收藏 0 赞 0 分享

问题:

<form...>下面的<input type="hidden" name="sortBy" id="sortBy" value="${sortBy}">占据物理位置的情况,代码如下:

<form name="header_product_search_form" method="post" id="header_product_search_form" action="${ctxPath }/products/productsSearch.html?doAction=productSearchAction">
<input type="hidden" name="headSearchCategoryPath" id="headSearchCategoryPath" value="${categoryPath }">
<input type="hidden" name="headSearchAttributePath" id="headSearchAttributePath" value="${headSearchAttributePath }">
<input type="hidden" name="attributePathInputValue" id="attributePathInputValue" value="${attributePathInputValue}">
<input type="hidden" name="PrmItemsPerPage" id="PrmItemsPerPage" value="${pagingBean.itemsPerPage}">
<input type="hidden" name="PrmPageNo" id="PrmPageNo" value="${pagingBean.currentPage}">
<input type="hidden" name="PrmTotalItems" id="PrmTotalItems" value="${pagingBean.numberOfItems}">
<input type="hidden" name="PrmTotalPages" id="PrmTotalPages" value="${pagingBean.numberOfPages}">
<input type="hidden" name="sortBy" id="sortBy" value="${sortBy}">

..............

..............

</form>

如上,红色的隐藏输入框直接在form标签下面,结果出现在ie下显示失真的情况,隐藏输入框占据物理空间,在ie里留下空白的部分。而在Firefox下显示正常。

解决方法:

把隐藏输入框放在form标签的最后面,即在</form>之上,ie下显示即可恢复正常。代码如下:

<form name="header_product_search_form" method="post" id="header_product_search_form" action="${ctxPath }/products/productsSearch.html?doAction=productSearchAction">

..............

..............
<input type="hidden" name="headSearchCategoryPath" id="headSearchCategoryPath" value="${categoryPath }">
<input type="hidden" name="headSearchAttributePath" id="headSearchAttributePath" value="${headSearchAttributePath }">
<input type="hidden" name="attributePathInputValue" id="attributePathInputValue" value="${attributePathInputValue}">
<input type="hidden" name="PrmItemsPerPage" id="PrmItemsPerPage" value="${pagingBean.itemsPerPage}">
<input type="hidden" name="PrmPageNo" id="PrmPageNo" value="${pagingBean.currentPage}">
<input type="hidden" name="PrmTotalItems" id="PrmTotalItems" value="${pagingBean.numberOfItems}">
<input type="hidden" name="PrmTotalPages" id="PrmTotalPages" value="${pagingBean.numberOfPages}">
<input type="hidden" name="sortBy" id="sortBy" value="${sortBy}">

</form>

更多精彩内容其他人还在看

超链接的宽度和高度直接设置不起作用的解决方法

这篇文章主要介绍了超链接的宽度和高度直接设置不起作用的解决方法,需要的朋友可以参考下
收藏 0 赞 0 分享

html下拉菜单提交后保留选中值而不返回默认值

这篇文章主要介绍了html下拉菜单提交后如何保留选中值而不返回默认值,方法虽简单,但比较实用,需要的朋友可以参考下
收藏 0 赞 0 分享

html用style添加属性示例

这篇文章主要介绍了html用style添加属性的写法,比较实用,有需要的朋友可以参考下
收藏 0 赞 0 分享

HTML元素设置焦点的方法

HTML元素设置焦点,大都是采用js的focus方法来进行设置,下面有个示例,大家可以参考下
收藏 0 赞 0 分享

html用title属性实现鼠标悬停显示文字

实现鼠标悬停显示文字,html中使用title属性就可实现显示文字的效果,这个属性还是比较实用的,需要的朋友可以参考下
收藏 0 赞 0 分享

html 用超链接打开新窗口其可控制窗口属性

这篇文章主要介绍了html如何用超链接打开新窗口其可控制窗口属性,主要使用到js的window.open方法,感兴趣的朋友可以看看哦
收藏 0 赞 0 分享

html 可输入下拉菜单的实现方法

可输入下拉菜单,不可思议是不是, 本例通过一些方法实现这个不可能的事情,感兴趣的朋友可以参考下
收藏 0 赞 0 分享

a标签href属性与onclick事件使用实例

a标签主要用来实现页面跳转,可以通过href属性实现,也可以在onclick事件里实现,下面为大家简要介绍下其具体的使用
收藏 0 赞 0 分享

HTML cellpadding与cellspacing属性图文详解

这篇文章主要介绍了HTML cellpadding与cellspacing属性,有个演示图,相信大家看过之后就知道了,需要的朋友可以参考下
收藏 0 赞 0 分享

input输入框中的光标大小显示不一致的解决方法

chrome浏览器对光标高度的设置原则为,当没有内容的时候光标的高度=input的line-height的值,当有内容时,光标从input的顶端到文字的底部
收藏 0 赞 0 分享
查看更多