这是一款背景跟随鼠标移动的jQuery插件,你可以自定义背景坐标。
淘建站为您提供更多_其它特效_jQuery插件_parallax_背景,在此特别感谢您对我们的支持与厚爱!
演示不了,点击反馈
下载 159 次
觉得不错,可打赏下作者
免费共享
背景图片.background,云图片.cloud
<img src="http://i.imgur.com/nJRyJYx.jpg" alt="New York" class="background">
<img src="http://i.imgur.com/bh4Si0q.png" alt="Clouds" class="cloud cloud1">
<img src="http://i.imgur.com/xvau4BM.png" alt="Clouds" class="cloud cloud2">引入相关插件
<script src="http://cdnjs.cloudflare.com/ajax/libs/gsap/1.17.0/TweenMax.min.js"></script>
<script src="js/jquery-parallax.js" type="text/javascript" charset="utf-8" ></script>当鼠标移动触发背景图片移动
$(document).mousemove(function(e) {
$('.background').parallax(-30, e);
$('.cloud1').parallax(10, e);
$('.cloud2').parallax(20, e);
});

