当你在TinyMCE的伸展你的表不过,我希望它被推翻,因为所有的表必须是100%的宽度打印否则它的外观,你得到这个我怎么可以在此改变CSS样式表中的
<table class="opbouw" style="width: 725px; height: 170px;" border="0" cellpadding="0" cellspacing="0">
蹩脚。
谁能告诉我如何overule它使打印
当你在TinyMCE的伸展你的表不过,我希望它被推翻,因为所有的表必须是100%的宽度打印否则它的外观,你得到这个我怎么可以在此改变CSS样式表中的
<table class="opbouw" style="width: 725px; height: 170px;" border="0" cellpadding="0" cellspacing="0">
蹩脚。
谁能告诉我如何overule它使打印
由于您的width
被内嵌设置与style
属性,您将无法覆盖它。 Sometimes not even !Important will override it.如果您可以将尺寸信息移动到某个班级,则可以在打印样式表中将宽度重置为100%。
如果你不想大小信息添加到类opbouw
,那么你就可以创建第二个类,例如,narrowTable
无一不适用于表所示:
<table class="opbouw narrowTable" ...>
在打印样式表可以重新设置大小属性:
<style type="text/css">
@media print
{
TABLE, .narrowTable
{
width: 100%;
margin: 0;
padding: 0;
}
}
@media screen
{
.opbouw
{
}
.narrowTable
{
width: 725px;
height: 150px;
border: none;
}
/* all your normal screen styles */
}
</style>
更多关于CSS选择器Specificty see this here,在网络上我最喜欢的CSS的文章(谁当多个样式指向同一元素胜)。
应用的!important
规则,它的结束时,该表是100%。
在你的CSS文件:
table {
width: 100% !important;
}