我正在建立我的網站,我有一些困難。這是它目前的樣子:對齊一系列的div
http://i1134.photobucket.com/albums/m618/eshellborn/ScreenShot2012-11-28at43250PM.png
,當然這是我希望它看起來:
http://i1134.photobucket.com/albums/m618/eshellborn/ScreenShot2012-11-28at43306PM.png
我試過這麼多的div這個對齊和類似的東西這一點,似乎沒有任何工作。有任何想法嗎?下面的代碼:
HTML:
<div class="realtor">
<img src="bronson.png" align="left" />
<div class="innerrealtor">
<h3>Bronson Carmichael</h3>
<p class="realtorinfo"> Bronson has been in the industry for thousands of years, with over 12 client expiriences. Join him on your journey to find a home in the Cranbrook area. </p>
</div>
<div class="viewlistings">
<div>View Bronson's Listings</div>
<img src="viewarrow.png" />
</div>
</div>
CSS:
.innerrealtor {
width: 450px;
margin-left: 90px;
margin-top: -3px;
}
.realtor {
padding: 15px;
margin-top: 25px;
background-color: #F9F8E7;
width: 750px;
height: 70px;
border-radius: 5px;
}
.viewlistings {
width: 180px;
height: 50px;
background-color: #018D0E;
border-radius: 4px;
float: right;
text-align: right;
}
.viewlistings div {
padding-top: 3px;
margin-right: 50px;
font-family: 'Sanchez', serif;
color: #ffffff;
font-size: 16px;
font-weight: 100;
}
.viewlistings img {
position: relative;
}
哇,這很簡單。仍然不完美,但使它好多了。稍後我會稍微擺弄一下,但謝謝。 – eshellborn