因此,每当我预先填充文本框并使用Chrome查看它时,它都不会显示我分配给文本框的样式。为什么?我会告诉你一张我的意思:
这是我的css代码:
input:-webkit-autofill {
-webkit-box-shadow: 0 0 0 50px #000 inset;
-webkit-text-fill-color: cyan;
-webkit-border-radius: 3px;
-webkit-transition: all 0.10s ease-in-out;
-moz-transition: all 0.10s ease-in-out;
transition: all 0.10s ease-in-out;
border: 1px solid #006161;
padding-left: 5px;
padding-right: 5px;
float: left;
outline: none;
opacity: 1.00;
border-radius: 3px;
background-color: #000;
color: cyan;
}
input:-webkit-autofill:focus {
-webkit-box-shadow: 0 0 0 50px #000 inset;
-webkit-text-fill-color: cyan;
-webkit-border-radius: 3px;
border: 1px solid cyan;
outline: none;
}
input:-webkit-autofill:hover {
-webkit-box-shadow: 0 0 0 50px #000 inset;
-webkit-text-fill-color: cyan;
-webkit-border-radius: 3px ;
border: 1px solid cyan;
outline: none;
}
.txt, INPUT[type="submit"]
{
background-color: #000;
color: cyan;
border: 1px solid #006161;
border-radius: 3px;
transition: all 0.10s ease-in-out;
-webkit-transition: all 0.10s ease-in-out;
-moz-transition: all 0.10s ease-in-out;
padding-left: 5px;
padding-right: 5px;
float: left;
}
.txt:focus, [type="submit"]:focus
{
opacity: 1.00;
background-color: #020202;
color: cyan;
outline: none;
border-color: cyan;
box-shadow: 0 0 10px cyan;
}
.txt:hover, INPUT[type="submit"]:hover
{
opacity: 1.00;
background-color: #000;
color: cyan;
outline: none;
border-color: cyan;
box-shadow: 0 0 10px cyan;
}

<input type='text' class='txt' name='settings[".$settings['email']['id']."]' value='".$emailAddress."' />
&#13;
提前致谢,
蓝宝石〜