开发者

jQuery not working as it should

开发者 https://www.devze.com 2023-02-02 05:34 出处:网络
I\'m trying to follow along the demo source code for the Draggable jQuery method, but the div cannot be dragged.

I'm trying to follow along the demo source code for the Draggable jQuery method, but the div cannot be dragged.

Here's my code:

<!DOCTYPE html>
<html>
<head>
    <title>@ViewBag.Title</title>
    <link href="@Url.Content("~/Content/Site.css")" rel="stylesheet" type="text/css" />
    <script src="@Url.Content("~/Scripts/jquery-1.4.4.min.js")" type="text/javascript"></script>

    <script>
        $(function () {
            $("#d开发者_StackOverflowraggable").draggable();
        });
    </script>
</head>

<body>
    <div id="draggable" class="ui-widget-content">
        <p>Drag me around</p>
    </div>
</body>
</html>

This is on a freshly created ASP.Net MVC3 application default start project. Thanks!


You need to include jQuery UI.

0

精彩评论

暂无评论...
验证码 换一张
取 消