- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Place the image at the bottom inside a Bootstrap 4 card
To place the image at the bottom inside a card, use the card-img-bottom class.
Firstly, set the card body and then use the <img> tag to add an image. The following code snippet is added inside the card class −
<div class="card-body"> <h4 class="card-title">Quantitative Aptitude</h4> <p class="card-text">For Entrance Exams</p> <a href="#" class="btn btn-primary">Sample Questions</a> </div> <img class="card-img-bottom" src="Image-Source " alt="Alt-Text" style="width:100%">
The following is an example to learn how to place image at the bottom inside a card in Bootstrap 4 −
Example
<!DOCTYPE html> <html lang="en"> <head> <title>Bootstrap Example</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.0/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.0/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h3>Quantitative Aptitude Questions Answers</h3> <div class="card" style="width:400px"> <div class="card-body"> <h4 class="card-title">Quantitative Aptitude</h4> <p class="card-text">For Entrance Exams</p> <a href="#" class="btn btn-primary">Sample Questions</a> </div> <img class="card-img-bottom" src="https://www.tutorialspoint.com/videotutorials/images/numerical_ability_home.jpg" alt="QA" style="width:100%"> </div> </div> </body> </html>
- Related Articles
- Place the image at the top inside a Bootstrap 4 card
- Bootstrap 4 .card-img-bottom class
- Add a hover effect inside the Bootstrap 4 card
- Style navigation tabs inside the Bootstrap 4 card header
- Style navigation pills inside the Bootstrap 4 card header
- Turn an image into a Bootstrap 4 card background
- Create a Bootstrap 4 card header
- Set positive action to the Bootstrap 4 card
- Set negative action to the Bootstrap 4 card
- Bootstrap 4 .card-text class
- Bootstrap 4 .card-header class
- Bootstrap 4 .card-link class
- Bootstrap 4 .card-footer class
- Bootstrap 4 .card-subtitle class
- Bootstrap 4 .card-body class

Advertisements