I am working with BootStrap and facing an issue with Jumbotrons. There are 2 divs on my page, the second one should suppose to take the remaining screen size. But when i am changing the browser height and width it's not adjusting accordingly as in the height of the div is not getting adjusted as it should.
HTML :
<div class="jumbotron" id="jumbo1">
<div class="container">
<h1>Some Txt.</h1>
</div>
</div>
<div class="jumbotron" id="jumbo2">
<p>
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuri.
</p>
<div class="container-fluid">
<section id="gly"> <span class="glyphicon glyphicon-arrow-down" aria-hidden="true" id="dwnarrow"></span>
</section>
</div>
</div>
CSS:
html,body
{
height: 100%;
width: 100%;
}
#jumbo1
{
height:auto;
}
#jumbo2
{
padding: 0px;
max-height: 100%;
}
#gly
{
text-align: center;
margin-top: 300px;
}
Can anyone tell what am I doing wrong here???
This is because of the max-height: 100%;
for #jubmo2
This should do the trick
html, body{
height:100%;
}
#jumbo1 {
height:100%;
}
.container-fluid {
text-align:center;
}
#gly {
display:inline;
position:absolute;
bottom:20px;
}
Try it directly in your page.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.