Html 使 Bootstrap 按钮透明
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/38493785/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Make Bootstrap Button Transparent
提问by James
How do I make my button transparent? I have been trying to use .btn-transparent but cant seem to get it to work. The button just keeps turning grey.
如何使我的按钮透明?我一直在尝试使用 .btn-transparent 但似乎无法让它工作。按钮只是一直变灰。
<p>
<!-- Search Button -->
<div class="container3">
<div class="btn-group ">
<button type="button" class="btn btn-primary-outline">SEARCH</button>
<button type="button" class="btn btn-primary-outline">
<span class="glyphicon glyphicon-menu-right"></span>
</button>
</div>
</div>
</p>
回答by saiful
make css to .btn-primary-outline
使 css 为 .btn-primary-outline
example like this : https://jsfiddle.net/472cxwg9/
像这样的例子:https: //jsfiddle.net/472cxwg9/
回答by Abdelwahid Oubaalla
回答by Red
You can do this in Bootstrap 4 without any in-line styling
您可以在 Bootstrap 4 中执行此操作,而无需任何内嵌样式
<button class="btn bg-transparent"></button>
回答by RandomUs1r
In bootstrap 3 I added:
在引导程序 3 中,我添加了:
.btn-primary-outline {
background-color: transparent;
border-color: transparent;
box-shadow: none;
}
To:
到:
<div class="col-xs-3" style="margin-top: 25px;">
<button type="button" class="btn btn-primary-outline">
<span style="display: inline; font-size: 30px; color: #007bff;" class="material-icons save">
</span>
</button>
</div>