<1>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>将一个ul下的li转移到另外一个ul里面</title>
<script src="script/jquery-1.11.0.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
//创建一个节点
var li = $("<li>中国队</li><li>美国队</li><li>巴西队</li><li>德国队</li>")
//给这个节点添加到#ul1里面
$("#ul1").append(li)
$("ul li").mouseover(function () {
$(this).css("background", "red").siblings().css("background", "White").click(function () {
//$(this).appendTo($("#ul2"))的意思是将当前的li添加到#ul2里面
$(this).appendTo($("#ul2")).css("background","white")
})
})
})
</script>
</head>
<body>
<ul id="ul1" style=" float:left"></ul>
<ul id="ul2"style=" float:right"></ul>
</body>
</html>