我使用本指南来自定义我使用bootstrap创建的网页中的按钮:
问题是我无法在悬停中保持相同的字体颜色,我无法解释为什么它总是变为深灰色.这是代码:http://codepen.io/anon/pen/ByKZZK
HTML:
<head>
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
</head>
<button href="mailto:abc@def.ghi" class="btn btn-custom btn-lg btn-block">info@mail.org <span class="glyphicon glyphicon-envelope"></span></button>
Run Code Online (Sandbox Code Playgroud)
CSS:
.btn-custom {
color: #FFD180;;
background-color: #483737;
border-color: #357ebd; /*set the color you want here*/
}
.btn-custom:hover, .btn-custom:focus, .btn-custom:active, .btn-custom.active, .open>.dropdown-toggle.btn-custom {
color: #FFD180;
background-color: #837171;
border-color: #837171; /*set the color you want here*/
}
Run Code Online (Sandbox Code Playgroud)
有任何想法吗?