2013-07-25 112 views
1

我有这个div:强和EM加价不显示正确

<div class="fieldFullTextReadOnly"> 
    <span style="color: #ff0000;"> 
    <strong>bold test</strong> 
    </span> 
    <span style="color: #ffc000;"> 
    <em>italic test</em> 
    </span> 
</div> 

相关的CSS:

.fieldFullTextReadOnly { 
    color: #167F78; 
    font-family: Arial; 
    font-size: 11px; 
    font-weight: normal; 
} 

在Firebug中,它显示的颜色被覆盖,这是右:

enter image description here

但是,无论是<strong>也不应用<em>,并且文本以正常体重持续显示。

发生了什么事?我可以改变什么来显示正确的字体重量的文字?

div内部的HTML由Telerik文本编辑器生成,所以我不能在这里更改任何内容。

谢谢。

回答

2

习惯了这种方式

.fieldFullTextReadOnly strong{font-weight:bold;} 
.fieldFullTextReadOnly em{font-style:italic;} 
0

你的文字设置为正常font-weight。 在您的CSS下添加这个项目:

.fieldFullTextReadOnly strong { 
    font-weight:bold; 
} 
.fieldFullTextReadOnly em { 
    font-style:italic; 
}