今天学习了bootsap,收获颇丰,这里分享一个小案例,具体的解释都在代码上,这样比较直观。
先看图例
Bootstrap选项卡 /*焦点样式图*/ div.hero-unit { /*背景样式,默认为灰色的*/ background: url(../img/bg.png) no-repeat; width: 980px; height: 443px; position: relative; /*默认为60px*/ padding: 0; /*默认为30px*/ margin: 0; border-color: gray; } div.hero-unit h1{ /*隐藏标题*/ display: none; } /*广告显示在左下角*/ div.hero-unit .banner { position: absolute; bottom: 0; left:10px; } /*按钮在右下角显示*/ div.hero-unit .btn { position: absolute; bottom: 14px; right: 20px; }
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持全福编程网。