jquery 实现背景图片循环切换,显示隐藏div
2014-09-18 17:24
971 查看
jquery实现图片背景循环切换,显示隐藏一个div。
<script type="text/javascript">
$(function(){
$("#table4").hide();
$(".o_record p span").toggle(function(){
$(this).addClass("o_span");
$("#table4").show();
},function(){
$(this).removeClass("o_span");
$("#table4").hide();
})
});
</script>
<stype type="text/css">
.o_layout .o_record p .o_span{ float:right; display:inline; width:60px; background:url(../images/20140918010340704_easyicon_net_16.png) no-repeat right;cursor:pointer;}
.o_up{ float:right; display:inline; width:60px;background:url(../images/20140918010354231_easyicon_net_16.png) no-repeat right; cursor:pointer;}
.o_layout .o_record .table4{margin-top:10px;}
</style>
<div class="o_record">
<p><i class="r_icon"></i>操作历史记录<span class="o_up">| 展开</span></p>
<div class="table4" id="table4">
<table>
<tbody>
<tr>
<th class="col_width2">操作者</th>
<th class="col_width2">操作时间</th>
<th class="col_width2">操作状态</th>
<th>备注</th>
</tr>
</tbody>
<tbody> <tr>
<th class="col_width2"></th>
<th class="col_width2"></th>
<th class="col_width2"></th>
<th></th>
</tr></tbody>
</table>
</div>
</div>
<script type="text/javascript">
$(function(){
$("#table4").hide();
$(".o_record p span").toggle(function(){
$(this).addClass("o_span");
$("#table4").show();
},function(){
$(this).removeClass("o_span");
$("#table4").hide();
})
});
</script>
<stype type="text/css">
.o_layout .o_record p .o_span{ float:right; display:inline; width:60px; background:url(../images/20140918010340704_easyicon_net_16.png) no-repeat right;cursor:pointer;}
.o_up{ float:right; display:inline; width:60px;background:url(../images/20140918010354231_easyicon_net_16.png) no-repeat right; cursor:pointer;}
.o_layout .o_record .table4{margin-top:10px;}
</style>
<div class="o_record">
<p><i class="r_icon"></i>操作历史记录<span class="o_up">| 展开</span></p>
<div class="table4" id="table4">
<table>
<tbody>
<tr>
<th class="col_width2">操作者</th>
<th class="col_width2">操作时间</th>
<th class="col_width2">操作状态</th>
<th>备注</th>
</tr>
</tbody>
<tbody> <tr>
<th class="col_width2"></th>
<th class="col_width2"></th>
<th class="col_width2"></th>
<th></th>
</tr></tbody>
</table>
</div>
</div>
相关文章推荐
- Jquery实现点击切换图片并隐藏显示内容(2种方法实现)
- Jquery实现点击切换图片并隐藏显示内容(2种方法实现)
- jQuery实现图片的隐藏、显示、切换
- jQuery点击按钮实现div的隐藏和显示切换效果
- Jquery实现点击切换图片并隐藏显示内容
- jquery 实现横向滑动自动切换源码(同时显示多张图片)
- 基于jQuery实现仿百度首页换肤背景图片切换代码
- jquery和js实现对div的隐藏和显示方法
- 基于jQuery实现仿百度首页换肤背景图片切换代码
- 使用jquery实现点击一个按钮或连接,让它下面的div显示,在点击一下隐藏
- 使用jquery点击一个实现button或连接,进行以下div显示,在点击隐藏
- jquery 实现点击其他地方隐藏之前点击显示的div标签等
- 利用AnimationDrawable实现控件的背景图片循环切换
- jQuery鼠标移动到Div上后切换背景,或更换图片
- JQuery实现开关灯及图片的显示,背景变暗
- jquery简单图片切换显示效果实现方法
- 用jQuery实现一些导航条切换,显示隐藏
- 基于jquery实现的定时显示与隐藏div广告的实现代码