[英]Ordered list displaying all <li>s as number 1 in Explorer 7
I've been alerted to a strange problem in IE7 that I can't locate a solution for. 我已经注意到IE7中的一个奇怪的问题,我无法找到解决方案。 I have a standard ordered list formatted properly, with all opening and closing tags intact.
我有一个正确格式化的标准有序列表,所有打开和关闭标签都完好无损。
<ol>
<li>Item 1</li>
<li>Item 2</li>
<li>Item 3</li>
<li>Item 4</li>
</ol>
All browsers display the list properly except Explorer 7 which renders the list as below: 所有浏览器都会正确显示列表,但Explorer 7除外,它会将列表呈现如下:
1. Item 1
1. Item 2
1. Item 3
1. Item 4
Has anyone experienced this issue before? 以前有没有人遇到过这个问题? Here's a link to the list.
这是列表的链接 。 Thanks for any suggestions.
谢谢你的任何建议。
I had the same issue before. 我以前遇到过同样的问题。 The following fixed my issue.
以下修复了我的问题。
ol li {
margin-left: 2em;
display: list-item;
list-style: inside decimal-leading-zero;
}
http://thedesignspace.net/MT2archives/000687.html http://thedesignspace.net/MT2archives/000687.html
This happens when a width is added to the "LI" tags in an ordered list.
将宽度添加到有序列表中的“LI”标记时会发生这种情况。 Internet Explorer 7 will not increment the numbers.
Internet Explorer 7不会增加数字。
I tried this in IE7, and it displays as it should. 我在IE7中尝试了这个 ,它显示它应该。
Try to validate the page to see if there are any errors elsewhere in the code. 尝试验证页面以查看代码中的其他位置是否存在任何错误。
I managed to see the problem in IE 9 in IE 7 mode, and playing around with the styles I found this: 我设法在IE 7模式下看到了IE 9中的问题,并且玩了我发现的样式:
Remove the zoom: 1;
删除
zoom: 1;
style from the #content LI
rule in universal.css
, and the numbering returns to normal. 来自
universal.css
#content LI
规则的样式,编号返回正常。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.