我有一个关于使按钮显示的图像 例如问题,我有四个按钮 我想显示在图像CSS ..我怎样才能使按钮显示的图像
在其他相同内容的图像中的每个按钮关键词: 当您按下其中一个按钮显示您的图像
这里有一个例子:http://jsfiddle.net/i5yal/yvCtQ/1/
<div id="section-container">
<div class="section-img-container"><a>images will appear here</a>
</div>
</div>
<div id="section-button-container"><div>
<div class="section-button1"><a>1</a>
</div>
<div class="section-button2"><a>2</a>
</div>
<div class="section-button3"><a>3</a>
</div>
<div class="section-button4"><a>4</a>
</div>
</div>
</div>
CSS代码:
#section-container {
background-color: #C0C0C0;
width: 300px;
height: 300px;
margin:0 auto;
}
#section-button-container {
width: 300px;
height: 30px;
margin:0 auto;
}
.section-button1 {
background-color: #808000;
width: 30px;
height: 30px;
float: left;
display: block;
margin-left: 30px;
margin-right: 20px;
}
.section-button2 {
background-color: #808000;
width: 30px;
height: 30px;
float: left;
display: block;
margin-left: 20px;
margin-right: 20px;
}
.section-button3 {
background-color: #808000;
width: 30px;
height: 30px;
float: left;
display: block;
margin-left: 20px;
margin-right: 20px;
}
.section-button4 {
background-color: #808000;
width: 30px;
height: 30px;
float: left;
display: block;
margin-left: 20px;
margin-right: 20px;
}
.section-img-container {
background-color: #008080;
background-position: center center;
width: 270px;
height: 270px;
margin: 0 auto;
}
对于辅助功能,为什么不做'' –
有几种方法可以做到这一点。如果你希望图像是可点击的(看起来你在那里看到一个锚标记),那么你可以有一个默认图像,说一个问号或你的锚点中的东西,然后用jQuery改变它的源代码。如果这是你想要评论的内容,我会为你发布一个例子。 – origin1tech
@ C.Hazelton + Ryan B 谢谢你的回答, 要清除我的问题我想要做的事情是这样的: http://tympanus.net/Development/BookBlock/index2.html – EXIT