为什么这个jquery简单的传输效果不起作用?

hh5*_*188 1 jquery user-interface transfer

正文html代码:

<div style="background:yellow;width:500px;height:300px;">
    <div id="div1" style="background:red; width:100px;height:100px; float:left;"></div>
    <div id="div2" style="background:blue; width:50px;height:50px; float:right;"></div>
</div>
Run Code Online (Sandbox Code Playgroud)

那么js代码:

 $(function () {
        $("#div1").click(function () {
            $(this).effect("transfer", { to: $("#div2") }, 1000);
            //$(this).effect("shake", { times: 2 }, 200);
        });
    });
Run Code Online (Sandbox Code Playgroud)

当然我已导入了

<script type="text/javascript" src="js/jquery-ui-1.8.5.custom.min.js"></script>
Run Code Online (Sandbox Code Playgroud)

你可以在网上看到坏消息:http://jsfiddle.net/hh54188/wz2J3/

下面的"摇动"效果可行,但转移不起作用,如何解决问题?谢谢

Joh*_*ker 7

来自http://docs.jquery.com/UI/Effects/Transfer

transfer元素iself具有类名"ui-effects-transfer",并且需要由您设置样式,例如通过添加背景或边框.

这是在这个例子中

.ui-effects-transfer { border: 2px solid black; }
Run Code Online (Sandbox Code Playgroud)