I created this div using bootstrap, I am running into an issue. I can\'t figure
ID: 3860281 • Letter: I
Question
I created this div using bootstrap, I am running into an issue. I can't figure out how to adjust the length of the alert info, when I view it, the border is too close to the text, I need help creating some space between the borders and text from top and bottom. Is there a way to do it without css? I can only use bootstrap. I also need help aligning the div in the middle without the use of margin and css.
<div class="row">
<div class="col-md-6 col-centered text-center">
<div>
<div class="alert-info"> <h4>Amount</h4>
<p class="alert-info">$25</p>
</div>
</div>
</div>
Explanation / Answer
I think you doing it wrong way:
<div class="alert-info"> <h4>Amount</h4>
here you entered alert-info class in wrong way it should be
<div class="alert alert-info">
then it will automatically adjust your text
here what I edit in your code:
<div class="row">
<div class="col-md-6 col-centered text-center">
<div>
<div class="alert alert-info"> <h4>Amount</h4>
<p >$25</p>
</div>
</div>
</div>
</div>
you will be fine just use class="alert alert-info" instead of just class="alert-info".
I hope this will help you. :)
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.