(085)jquery_jqueryui_sortable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"> <html> <head> <title>sortable.html</title> <meta http-equiv="keywords" content="keyword1,keyword2,keyword3"> <meta http-equiv="description" content="this is my page"> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <!--<link rel="stylesheet" type="text/css" href="./styles.css">--> <style> #divtest { width: 282px; } #divtest .title { padding: 8px; background-color:blue; color:#fff; height: 23px; line-height: 23px; font-size: 15px; font-weight: bold; } ul { float: left; width: 280px; padding: 5px 0px; margin: 0px; font-size: 14px; list-style-type: none; } ul li { float: left; width: 264px; height: 32px; line-height: 32px; padding: 3px 8px; border:solid 1px #ccc; background-color:#eee; cursor:move; margin:2px 0px; } .fl { float: left; } .fr { float: right; } </style> <script type="text/javascript" src="../js/jquery/jquery-1.8.3.min.js"></script> <script type="text/javascript" src="../js/jqueryui/jquery-ui-1.9.2.min.js"></script> <script type="text/javascript"> $(function(){ $("ul").sortable({ delay:2, //为防止与点击事件冲突,延时2秒 opacity:0.35 //以透明度0.35随意拖动 }); }); </script> </head> <body> <div id="divtest"> <div class="title"> <span class="fl">我最喜欢的运动</span> </div> <div class="content"> <ul> <li>1)足球</li> <li>2)散步</li> <li>3)篮球</li> <li>4)乒乓球</li> <li>5)骑自行车</li> </ul> </div> </div> </body> </html>
***万事万物都有裂痕,那是光照进来的地方***

浙公网安备 33010602011771号