I want to set the jumbotron to 0.5 opacity.
<div class="jumbotron">
<table id="white" class="table table-condensed" id="table">
<tbody>
<tr>
<td>En</td>
<th>1</th>
</tr>
<tr>
<td>To</td>
<th>2</th>
</tr>
</tbody>
</table>
</div>
Is there a way to do this on just the jumbotron and not the table?
Jumbotron background color can be easily override using custom style tag which we have use inside our DIV tag. Just define style=”background-color:#00F3FF” inside your DIV and it will override the default background color and set your new color choice.
In Bootstrap 5 the jumbotron component is removed in favor of utility classes like . bg-light for the background color and .
Use RGBa
.jumbotron {
background: rgb(200, 54, 54); /* This is for ie8 and below */
background: rgba(200, 54, 54, 0.5);
}
Last value on the second line (0.5) is the opacity.
For clarity this won't work on ie8 or below as rgba is not supported.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With