[英]background color property not taking in print css
我試圖在print css中為我的標簽提供背景顏色。 它采用邊框顏色,但不采用css的background-color屬性。 怎么解決?
http://jsfiddle.net/gVLeg/embedded/result/
#stateLabelLeftSo {
display: inline-block;
margin-left: 4px;
border: 1px solid red;
background-color: green;
}
@media print {
body {
margin:0;
padding:0;
line-height: 1.4em;
word-spacing:1px;
letter-spacing:0.2px;
font: 12px Arial, Helvetica,"Lucida Grande", serif;
color: #000;
}
.mainDiv {
display: none;
}
#soLeft {
width: 300px;
border: 1px solid red;
background-color: green;
}
#billTextSO {
width: 101px;
}
#attentionTextSo {
width: 101px;
}
#addressTextSo {
width: 101px;
}
#cityTextSo {
width: 40px;
margin-left: 5px;
height: 13px;
}
默認情況下無法打印css中的background-color,也不建議使用。 背景顏色可以覆蓋文本。 如果你想要一些背景,你可以直接使用圖像。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.