我有2行,一個需要兩個圖像,另一個需要顯示信息,如果這些圖像被點擊。集中具有onclick元素的嵌套Divs
我有一個問題集中在行div中的圖像和文本。
<div id="container">
<!-- Image row -->
<div class="row">
<div class="col-md-6">
<div id="badbutton"><a href="#" onclick="showHide('bad')"></a></div>
</div>
<div class="col-md-6">
<div id="goodbutton"><a href="#" onclick="showHide('good')"></a></div>
</div>
</div>
<!-- Text Row -->
<div class="row">
<div class="col-md-6">
<div id="bad" style="display:none;">
<p>Oh no! We'd appreciate it if you'd share your experience with us so we can improve in the future. Just click below to get started.</p>
<p> FORM HERE </p>
</div>
</div>
<div class="col-md-6">
<div id="good" style="display:none;">
<p>Fantastic! Please share your experience with the world on of these popular websites. Just make a selection below to get started.</p>
<ol>
<li>Click here to review us on Google+ Reviews</li>
<li>Click here to review us on Facebook</li>
</ol>
</div>
</div>
</div>
</div>
發生了什麼事是COL-MD-6佔據該行格的45%,但裏面的按鈕不集中自己。
這裏是CSS:
.row {
margin: 0 auto;
}
.col-md-6 {
position: relative;
min-height: 1px;
padding-right: 15px;
padding-left: 15px;
}
.col-md-6 {
width: 45%;
}
#good,
#bad {
width: 50%;
}
這裏是結果:
樣品小提琴製作小提琴確切的問題 – Era 2015-02-10 11:49:15
是否使用Twitter的引導來獲得,如果是哪個版本? – abhiklpm 2015-02-10 12:15:26
@abhiklpm我使用了標準引導程序中的行和列元素 – 2015-02-10 12:16:32