我想要拿出一些CSS来匹配我在我的iPhone/Android应用程序中的样式。我有不透明的交替行颜色,所以我的自定义页面背景流血。但是,我遇到的问题是我不希望表单元格中的文本也不透明。我希望文本的透明度为1.0,背景为不透明度= 0.12。看到它现在看起来像here。下面CSS3交替表行不透明度影响文本以及背景
CSS:
html {
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
height: 100%;
background-image: url(../images/[email protected]);
}
table {
background-color: transparent;
margin-left: 0px;
margin-right: 0px;
margin-top: 10;
height: 100%;
width: 100%;
border: 0;
border-collapse: collapse;
}
tr {
text-align: center;
padding: 0;
}
td {
font-family: verdana;
color: #ffffff;
text-shadow: 1px 1px 1px #77777777, 2px 2px 7px #ff0000;
padding: 0;
}
tr:nth-child(odd) { background-color:#003366; opacity:.12; filter:alpha(12); }
tr:nth-child(even) { background-color:#6a737d; opacity:.12; filter:alpha(12); }
是的,工作。谢谢。 – LiteWait