jQuery的fadeTo方法调整图片的透明度
2013-05-06 15:45
337 查看
<head>
<title></title>
<style type="text/css">
.imgclass{ width:300px; height:300px; border:solid 1px red;}
</style>
<script src="jquery-1.9.1.js" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
$('#Select1').change(function () {
var thevalue = $(this).val();
$('img').fadeTo(2000, thevalue);
})
})
</script>
</head>
<body>
<table>
<tr>
<td>
透明度:
<select id="Select1">
<option value="0">0</option>
<option value="0.2">0.2</option>
<option value="0.4">0.4</option>
<option value="0.6">0.6</option>
<option value="0.8">0.8</option>
<option value="1">1</option>
</select>
</td>
<td>
<img src="images/泪奔1.gif" class="imgclass" />
</td>
</tr>
</table>
</body>
<title></title>
<style type="text/css">
.imgclass{ width:300px; height:300px; border:solid 1px red;}
</style>
<script src="jquery-1.9.1.js" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
$('#Select1').change(function () {
var thevalue = $(this).val();
$('img').fadeTo(2000, thevalue);
})
})
</script>
</head>
<body>
<table>
<tr>
<td>
透明度:
<select id="Select1">
<option value="0">0</option>
<option value="0.2">0.2</option>
<option value="0.4">0.4</option>
<option value="0.6">0.6</option>
<option value="0.8">0.8</option>
<option value="1">1</option>
</select>
</td>
<td>
<img src="images/泪奔1.gif" class="imgclass" />
</td>
</tr>
</table>
</body>
相关文章推荐
- jQuery fadeTo方法调整图片的透明度使用介绍
- 透明度nulljQuery的fadeTo方法调整图片的透明度
- jQuery fadeTo方法调整图片的透明度使用介绍
- 【JQuery】使用fadeTo()方法设置淡入淡出效果的不透明度
- jQuery中fadeIn、fadeOut、fadeTo的使用方法(图片显示与隐藏)
- 【jQuery】使用fadeTo()方法设置淡入淡出效果的不透明度
- jQuery中fadeIn、fadeOut、fadeTo的使用方法(图片显示与隐藏)
- 解决IE6下PNG图片背景不透明的三种方法(CSS/JS/JQuery)
- jquery渐隐渐显的图片幻灯闪烁切换实现方法
- jquery插件lazyload.js延迟加载图片的使用方法
- Android图片大小调整动态实现方法(bitmap)
- 简单jquery图片预览插件的使用方法
- JQuery实现鼠标移动图片显示描述层的方法
- 使用jquery获取网页中图片高度的两种方法
- jQuery lazyLoad图片延迟加载插件的优化改造方法分享
- php实现在服务器端调整图片大小的方法
- jquery实现图片左右切换的方法
- Jquery中使用show()与hide()方法动画显示和隐藏图片
- 两种图片延迟加载的方法总结jquery.scrollLoading.js与jquery.lazyload.js
- jQuery插件,图片切割效果,配合PHP可以实现图片切割和调整尺寸