我试图在下拉选项上应用一些CSS类。 CSS在Firefox中正确应用,但在IE(7,8)中,只有颜色被应用。任何机构都可以告诉我如何在IE 7和IE 8的下拉选项上应用样式。
.regionOption { font-weight:bold; } .countryOption { margin-left:10px; padding-left:5px; }根据条件,我在选项上使用这些CSS类。他们在Firefox中工作得很好。
我想显示区域和国家之间的区别,有没有其他方法?
感谢 Ashwani
解决方案目前支持选项元素的全部样式。
支持样式的完整列表出现在以下MSDN文章标题为样式的部分中:
http ://msdn.microsoft/en-us/library/ms535877%28VS.85%29.aspx
I am trying to apply some CSS class on the options of a drop down. The CSS apply correctly in Firefox, but in IE (7, 8) only color is getting applied. Can any body tell me how to apply styles on options of drop down for IE 7 and IE 8.
.regionOption { font-weight: bold; } .countryOption { margin-left: 10px; padding-left:5px; }I am using these CSS classes on options depending upon conditions. They work fine in Firefox.
I want to show difference between Region and country, is there any other way?
Thanks Ashwani
解决方案Internet Explorer does not currently support the full range of styles on option elements.
The full list of supported styles appears on the following MSDN article under the section titled "Styles":
msdn.microsoft/en-us/library/ms535877%28VS.85%29.aspx
更多推荐
如何将不同的样式应用于HTML中选择标签的选项
发布评论