I'm trying to make my image to fit the whole container width.
I've tried :
width="100%"
100%
None of those work.
<div class="container" style="background-color:gray;">
<div width="100%">
<img width="100%" src="http://s6.postimg.org/7ic0egypt/report_nav.png">
</div>
</div
此处将其添加到您的CSS中,默认情况下,正文的边距为8px。
body{margin: 0px;}
Set the container padding to 0
. I rewrote your fiddle using CSS
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.