我試圖把img放在另一個img上,因爲我想要一個剪貼簿的效果,圖像被「錄製」到主頁中。需要幫助定位「磁帶」img在另一個img
我想保持磁帶層的一致性並釋放自己以更改下面的圖像而不會丟失位置。
HTML:
<div id="container">
<div id="content">
<img class="gesture" src="http://i.imgur.com/rWgpQ6b.jpg" alt="Rain Hands" title="Rain Hands" />
<img class="tape" src="http://oi50.tinypic.com/nezz12.jpg" alt="tape" title="tape" />
<div class="text">
<h2>Rain Hands</h2>
<p>"When someone complains, 'I just felt a raindrop!,' the easiest way to prove his or her statement is to break out the Rain Hands. Hold both hands, palms facing upwards, out towards the sky. If you feel drops, then it is indeed raining. If you don't, then it isn't. Rain hands are fool-proof."<br /><br /><strong>Submitted By: </strong>Shaun</p>
</div>
</div>
</div>
CSS:
.gesture {
margin-left: 0;
margin-top: 45px;
width: 350px;
float: left; }
.tape {
margin-left: 10px;
margin-top: 45px;
position: absolute;
float: left;
width: 350px;
z-index: 1;}
我得到的是:
http://oi50.tinypic.com/28s8x8j.jpg
但我想的磁帶上的邊角頂部圖片。
磁帶是'.jpg'圖像..你不需要透明的圖像嗎? – Aprillion