I have encountered similar questions and attempted the suggested solutions without success *
My custom CSS file is correctly linked 100% to the HTML file I am working on *
I am utilizing Bootstrap v4.3.1 *
As the heading implies, my goal is to align text within a Bootstrap button using my own custom CSS file.
I have created a new style.css file and linked it in the header (after the Bootstrap CSS link), then I included a custom class (btn1) to my Bootstrap button:
<!-- Button trigger modal -->
<button type="button" class="btn btn-primary btn1" data-toggle="modal" data-target="#exampleModal">
Launch demo modal
</button>
Next, I added the following code to my CSS:
.btn1{
text-align: left !important;
}
However, the text on the button remains unaligned to the left. Any insights on why this may be happening, and suggestions on how to resolve the issue would be greatly appreciated.
Thank you!