Bootstrap 4 .card-footer class

BootstrapWeb DevelopmentCSS Framework

Use the card-footer class in Bootstrap 4 to set the footer of a Bootstrap card.

Add it using the class −

<div class="card-footer">
  Add footer message here
</div>

The card-footer class comes after the card-header and card-body class −

<div class="card">
  <div class="card-header">Details</div>
  <div class="card-body">Timings: 4PM - 8PM</div>
  <div class="card-footer">Reach before 4PM</div>
</div>

You can try to run the following code to implement the card-footer class −

Example

Live Demo

<!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">
    <h2>Conference</h2>
    <div class="card">
      <div class="card-header">Details</div>
      <div class="card-body">Timings: 4PM - 8PM</div>
      <div class="card-footer">Reach before 4PM</div>
    </div>
  </div>

</body>
</html>
raja
Published on 17-Jul-2018 14:35:38
Advertisements