努力試圖讓下面這個圖片:CSS的float:左不在這裏
但這裏是我所代替:
我使用這個代碼如下:
HTML:
<div class="floatright" style="width: 50%;">
<div class="floatleft" style="width: 35%;">
<img src="images/exhibitingopportunities.png" alt="Exhibiting Opportunities" style="border: none; width: auto; max-width: 100%;" />
</div>
<div class="floatleft sidespadding" style="width: 65%;">
<h4>Exhibiting Opportunities</h4>
<p class="desc">The Opportunity Finance Network Conference is a great place to connect with decision makers across the industry. Reserve your booth space now—contact Katie Kirchner for more information.</p>
</div>
</div>
<div style="width: 50%;">
<div class="floatleft" style="width: 35%;">
<img src="images/sponsorship_opportunities.png" alt="Sponsorship Opportunities" style="border: none; width: auto; max-width: 100%;" />
</div>
<div class="floatleft sidespadding" style="width: 65%;">
<h4>Sponsorship Opportunities</h4>
<p class="desc">Reserve your slot now to be a part of the CDFI industry's premier event! The OFN Conference provides our partners with an unparalleled platform to connect with CDFIs, increase awareness of their organizations' work, and support and strengthen the practice of opportunity finance.</p>
</div>
</div>
CSS:
.floatleft
{
float: left;
}
.floatright
{
float: right;
}
.sidespadding
{
padding-left: 1.2em;
padding-right: 1.2em;
}
.clear
{
clear: both;
}
無法獲取文字浮到實際圖像的左側,就像第一張圖的圖像。 OMG,我在這裏錯過了什麼?網頁在這裏:http://opportunityfinance.net/Test/2013conf/index.html
謝謝,這非常有幫助! –