Bootstrap 5 Programs .: Shivanshu 4NN21CS050 1.fixed Container
Bootstrap 5 Programs .: Shivanshu 4NN21CS050 1.fixed Container
PROGRAMS….
SHIVANSHU
4NN21CS050
1.FIXED CONTAINER
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/b
ootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/boo
tstrap.bundle.min.js"></script>
</head>
<body>
<div class="container">
<h1>My First Bootstrap Page</h1>
<p>This part is inside a .container class.</p>
<p>The .container class provides a responsive fixed width
container.</p>
<p>Resize the browser window to see that the container
width will change at different breakpoints.</p>
</div>
</body>
</html>
2.FLUID CONTAINER
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/b
ootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/boo
tstrap.bundle.min.js"></script>
</head>
<body>
<div class="container-fluid">
<h1>My First Bootstrap Page</h1>
<p>This part is inside a .container-fluid class.</p>
<p>The .container-fluid class provides a full width container,
spanning the entire width of the viewport.</p>
</div>
</body>
</html>
</body>
</html>
</body>
</html>
7. Bootstrap 5 Text/Typography
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/b
ootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/boo
tstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
8. Text Colors
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
9. Background Colors
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container mt-3">
<h2>Contextual Backgrounds</h2>
<p>Use the contextual background classes to provide
"meaning through colors".</p>
<div class="bg-primary p-3"></div>
<div class="bg-success p-3"></div>
<div class="bg-info p-3"></div>
<div class="bg-warning p-3"></div>
<div class="bg-danger p-3"></div>
<div class="bg-secondary p-3"></div>
<div class="bg-dark p-3"></div>
<div class="bg-light p-3"></div>
</div>
</body>
</html>
10. Basic Table
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<h2>Basic Table</h2>
<table class="table">
<thead>
<tr>
<th>Firstname</th>
<th>Lastname</th>
<th>Email</th>
</tr>
</thead>
<tbody>
<tr>
<td>John</td>
<td>Doe</td>
<td>[email protected]</td>
</tr>
<tr>
<td>Mary</td>
<td>Moe</td>
<td>[email protected]</td>
</tr>
<tr>
<td>July</td>
<td>Dooley</td>
<td>[email protected]</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<h2>Rounded Corners</h2>
</div>
</body>
</html>
12. ALERTS
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container mt-3">
<h2>Alerts</h2>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container mt-3">
<h2>Alert Links</h2>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
<div class="container mt-3">
<h2>Button Styles</h2>
</div>
</body>
</html>
</body>
</html>
</body>
</html>
</body>
</html>
</body>
</html>
</body>
</html>
</body>
</html>
23. Card Images
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
<div class="dropdown">
<button type="button" class="btn btn-primary
dropdown-toggle" data-bs-toggle="dropdown">
Dropdown button
</button>
<ul class="dropdown-menu">
<li><h5 class="dropdown-header">Dropdown header
1</h5></li>
<li><a class="dropdown-item" href="#">Link
1</a></li>
<li><a class="dropdown-item" href="#">Link
2</a></li>
<li><a class="dropdown-item" href="#">Link
3</a></li>
<li><h5 class="dropdown-header">Dropdown header
2</h5></li>
<li><a class="dropdown-item" href="#">Another
link</a></li>
</ul>
</div>
</div>
</body>
</html>
</body>
</html>
</body>
</html>
27. Modals
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
28. Toasts
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
29. Offcanvas
<!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
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/c
ss/bootstrap.min.css" rel="stylesheet">
<script
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/
bootstrap.bundle.min.js"></script>
</head>
<body>
</body>
</html>
</body>
</html>
</body>
</html>