我试图复制一个jsfiddle无济于事

Tit*_*mer 0 jquery

我对jquery很绿,所以不要太苛刻.这是我试图使用http://jsfiddle.net/RBKaZ/的jsfiddle .我在线上收到错误$("#dialog").dialog({:

Object不支持此属性或方法.

除了在jsfiddle上,Div显示不同.

这是我的页面:

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default4.aspx.vb" Inherits="Default4" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0     Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">

<script src="Scripts/jquery-1.9.1.js" type="text/javascript"></script>

<script type="text/javascript">
$("#dialog").dialog({
    autoOpen: false,
    buttons: {
        Ok: function () {
            $("#nameentered").text($("#name").val());
            $(this).dialog("close");
        },
        Cancel: function () {
            $(this).dialog("close");
        }
    }
});

$("#open").click(function () {
    $("#dialog").dialog("open");
})
</script>

<title></title>
</head>
<body>
    <form id="form1" runat="server">

<div id="dialog">
    <p>Please enter your name</p>
    <textarea id="name"></textarea>
</div>

<label>Name entered: </label>
<label id="nameentered"></label>
<br />
<input type="button" id="open" value="Open Dialog" />

    </form>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)

我从jquery.com下载了jquery-1.9.1.js并将其放在我的脚本文件夹中.在jsfiddle,他们说他们使用jquery UI 1.9.2.我错过了什么吗?在此先感谢您的帮助.

编辑 我添加了这个,我摆脱了不支持的对象错误,但它仍然没有做任何事情.

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

tym*_*eJV 5

在jQuery脚本下添加此脚本(jQuery UI):

<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js"></script>
Run Code Online (Sandbox Code Playgroud)