我正在使用jQuery更改点击后图像的大小。无论点击后图像的大小如何,我怎样才能保持右上角的关闭按钮。 JSFIDDLE试图保持图像包含在另一个图像
我的CSS
#full_image {
width: 0px;
height: 0px;
left: 0px;
position: relative;
opacity: 1;
z-index: 9;
}
#full_image img {
background: url("zoom-on.png") no-repeat;
background-position: 5px 5px;
left: 0px;
width: 339px;
height: 211px;
position: relative;
overflow: hidden;
}
#full_image .full_close{
background: url("zoom-on.png") no-repeat;
top: 10px;
cursor: pointer;
height: 29px;
opacity: 1;
position: absolute;
width: 29px;
z-index: 999;
right: 0px;
}
我的HTML
<div id="full_image"><img src=""/>
<span> <a href="#" class="full_close"></a></span>
</div>
的事情是我能保持包含#full_image内的图像,但我需要它含有#full_image IMG
如果你想得到实际的帮助,请填写完整的jsFidlle。 – avrahamcool
你是说'我需要它包含在#full_image img'中是什么意思? –
#full_image img是什么实际上包含图像#full_image是一个容器,后一些jquery动画变得大于图像,因此这就是为什么我需要其他图像包含在#full_image img –