ITeye博客

jquery图片预览功能

jyangzi5 · 2014-01-07 17:13 · JS · Web前端 · Markdown

<!DOCTYPE html>
<html>
<head>
  <script type="text/javascript" src="/jquery/jquery.js"></script>
</head>

<body>
  <p><input type="button" value="1"></p>
  <p><input type="button" value="2"></p>
  <p><input type="button" value="3"></p>

<script>
$(document).ready(function(){
 

   $("p").click(function(){
   
   var next = $(this).next();

    var temp = $(this).remove();
        next.after(temp);

 
});

});

</script>

</body>
</html>

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。