jQuery动画效果
jQuery动画效果 1、元素的显示和隐藏 display:none; 隐藏 display:block; 显示 a) show() 显示 b) hide() 隐藏 c) toggle() 开关, 显示则隐藏,隐藏则显示 <script type="text/javascript"> function f1(){ //隐藏 $("div").hide();//display:none //document.getElementById('id').style.display="none"; } function f2(){ //显示 $("div").show();//display:block } function f3(){ $("div").toggle(); } </script> <style type="text/css"> div {width:300px; height:200px; background-color:blue;} </style> <body> <div>duck and dog</div> <input type="button" value="隐藏" onclick="f1()" /> <input type="button" value="显示" onclick="f2()" /> <input type="button" value=