Online: 9642
A well is a container in <div> that causes the content to appear color or an inset effect on the page.
<body>
<div class="well">This is well used in bootsrap</div>
</body>
In the above code snippet we have defined well,
<div class=well>- renders well
output
Well sizes
It contains different sizes they are
<div class="container">
<div class="well well-sm">This is well used in bootsrap</div>
<div class="well">This is well used in bootsrap</div>
<div class="well well-lg">This is well used in bootsrap</div>
</div>
In the above code snippetwe are using the sizes of the well. We are having the sizes of the well as
<well-sm>-renders small size well <well-lg>-renders large size well output
We can change the color of the well using css
<style>
.well {
background-color: rgb(22, 105, 173);
}
</style>
</head>
<body>
<h2>Basic well</h2>
<div class="well">This is well used in bootsrap</div>
</body>
In the above code snippet we have change the color of the well using style sheet
output
We can set the height and width of the well using stylesheet
<style>
.well {
height: 150px;
width: 50%;
color: black;
background-color: green;
}
</style>
</head>
<body>
<h2>Well height and width</h2>
<div class="well">
<div>
<p>Really long text...</p>
</div>
</div>
</body>
In the above code snippet we have defined the wel height and width by using style sheet , we have given the well height as 150px and width as 80 % of the screen
output