<div class="row">
<div class="col-xs-3">
<img src="image/t.png " class="img-responsive">
</div>
<div class="col-xs-9 ">
<img src="image/b.png " class="img-responsive">
</div>
</div>
I want b.png
image to be right-align.
Place the image at the required line inside the <body> tag. Wrap the image element in . float-left class for aligning towards left, . float-right to align towards right.
Answer: Use the center-block Classcenter-block on it, along with the . img-responsive class in Bootstrap 3.
Aligning images block -level images can be centered using the .mx-auto margin utility class.
To create image and text side by side use the grid system property of bootstrap and create 2 columns of span 6-6. Put your image in one column and your text in another. On smaller devices, it will automatically align vertically.
You just need to add .pull-right
class.
So it will be like this example :
<div class="row">
<div class="col-xs-3">
<img src="image/t.png " class="img-responsive">
</div>
<div class="col-xs-9 ">
<img src="image/b.png " class="pull-right img-responsive">
</div>
</div>
Just add the pull-right
bootstrap class
<div class="col-xs-9 ">
<img src="image/b.png " class="img-responsive pull-right">
</div>
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