0
我正在为我的项目做我的投资组合。我开始编写布局并放置一些导航栏,图像,标题等。我将船图像放在内容背景中。但是,当我将幻灯片放在内容中时,飞船图像将移动到布局的底部。我尝试通过使用div标记并设置background-image:url来修复,以便两个图像不会相互碰撞,但是当我尝试设置背景位置时,船的图像位置不会移动。我真的不知道如何解决这个问题:(努力在我的背景图片上设置位置
CSS
#ship{
background-image:url(image/ship.png) no repeat;
// Both background-position and padding won't work
}
**Home Page**
<div id="content">
<img src="image/welcome.png">
<div id="slider"> <---- slideshow
<a href="#" class="control_next">>></a>
<a href="#" class="control_prev"><</a>
<ul>
<li></li>
....
</ul>
</div>
<div class="slider_option">
<input type="checkbox" id="checkbox">
<label for="checkbox">Autoplay Slider</label>
<img src="image/ship.png" id="ship"> <---background image
</div>
</div>