<html>
<head>
<script type="text/javascript" src="jquery.1.2.6.js"></script>
<script type="text/javascript">
jQuery.fn.slideLeftHide = function( speed, callback ) {
this.animate({
width : "hide",
paddingLeft : "hide",
paddingRight : "hide",
marginLeft : "hide",
marginRight : "hide"
}, speed, callback );
};
jQuery.fn.slideLeftShow = function( speed, callback ) {
this.animate({
width : "show",
paddingLeft : "show",
paddingRight : "show",
marginLeft : "show",
marginRight : "show"
}, speed, callback );
};
</script>
<script type="text/javascript">
$(function() {
$(".title_bar").slideLeftHide(4000);
$(".title_bar").slideLeftShow(4000);
});
</script>
</head>
<body>
<div class="title_bar">
<img src="recruitment.png" border="0"
/>
</div>
</body>
</html>
jquery写的slideLeft,slideRight
最新推荐文章于 2023-07-29 18:00:27 发布