Html Jumbotron背景图像不是';t显示全宽
我的Jumbotrons背景图像不是很全宽 知道为什么吗 实时链接: 你可以看到背景图像的宽度没有导航栏那么远 HTMLHtml Jumbotron背景图像不是';t显示全宽,html,css,twitter-bootstrap,Html,Css,Twitter Bootstrap,我的Jumbotrons背景图像不是很全宽 知道为什么吗 实时链接: 你可以看到背景图像的宽度没有导航栏那么远 HTML <div class="container special"> <div class="jumbotron"> <div class="container text-center"> <div class="h1extrapadding hidden-xs hidden-sm"></div> <h
<div class="container special">
<div class="jumbotron">
<div class="container text-center">
<div class="h1extrapadding hidden-xs hidden-sm"></div> <h1 class="boldme">Aged 20-30 & frustrated with money?</h1>
<div class="greenpromobox">
<div class="h2extrapadding hidden-xs hidden-sm"></div> <h2 class="boldme">Take our free <b class="jumpstarttext">Jumpstart Your Finances</b> class to<br /> quickly gain control over your finances</h2>
<!-- Begin MailChimp Signup Form -->
<div id="mc_embed_signup">
<form action="//moneynest.us11.list-manage.com/subscribe/post?u=9ccf2d2219536b32eaae3c3d1&id=299de51b4e" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
<img src="http://185.123.96.102/~kidsdrum/moneynest.co.uk/img/hand-drawn-arrow.png" id="handarrow" class="hidden-xs hidden-sm" alt="arrow"><input type="email" value="" name="EMAIL" class="email" id="mce-EMAIL" placeholder="Enter your email address" required autofocus>
<!-- real people should not fill this in and expect good things - do not remove this or risk form bot signups-->
<div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_9ccf2d2219536b32eaae3c3d1_299de51b4e" tabindex="-1" value=""></div>
<div class="clear"><input type="submit" value="Start Class Now" name="subscribe" id="mc-embedded-subscribe" class="text-uppercase btn btn-primary btn-lg"></div>
</div>
</form>
</div>
<!--End mc_embed_signup-->
</div>
</div>
</div>
</div>
</div>
我认为您的问题可能是
html
和body
标记上的默认边距或填充。尝试:
html, body {
margin: 0px;
padding: 0px;
}
不确定这是否有效,但值得一试。原因是bootstrap的
容器
类占用了左右两侧的填充空间。如果删除此类,图像将占据整个屏幕
或者,您可以使用容器流体
类
引导需要一个包含元素来包装站点内容并容纳我们的网格系统。您可以从两个容器中选择一个用于项目中。注意,由于填充和其他原因,两个容器都不可嵌套
将.container用于响应固定宽度的容器
使用.container流体作为全宽容器,跨越视口的整个宽度
我在Chrome的开发者工具中测试了它,并修复了它。这是因为您添加了类容器,从第一个div中删除这个类,它将解决您的问题
至
非常感谢,这一定是一些引导默认值。知道我为什么被否决吗?我不知道。。。我认为这是因为人们不想调试代码,但老实说,我不在乎这种或那种方式。还有一个。哈哈,别担心,我是新来的,想把一切弄清楚!我也是。我只有175名代表,也是一名或多或少的网络开发业余爱好者,但我之前也遇到过这个问题,并在网上找到了答案,所以我抓住机会回答了这个问题。这是有道理的,但对我不起作用,在我使用上述解决方案修复后,你可能已经刷新了?
html, body {
margin: 0px;
padding: 0px;
}