求大神指点?哪里有问题?
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script src="http://libs.baidu.com/jquery/1.9.0/jquery.js" type="text/javascript"></script>
<style type="text/css">
div{
position:absolute;
top:50px;
left:200px;
height:50px;
width:50px;
border:1px solid red;
}
</style>
<title>jQuery动画特效</title>
</head>
<body>
<input type="button" value="左移" id="leftb">
<input type="button" value="右移" id="rightb">
<div></div>
<script>
$(function(){
$("#leftb").click(function(){
$("div").animate({
left: "-=50px"
},2000,function(){
$("div").html("正在左移");
})
});
$("#rightb").click(function(){
$("div").animate({
right: "+=50px"
},2000,function(){
$("div").html("正在右移");
})
})
});
</script>
</body>
</html>