开发者

JQueryUI draggable "Object doesn't support this property or method" when jquery-ui is included

I've got the classic Object doesn't support this property or method message when using JQuery UI.

Hovever, this has come up after integrating my work into another solution.

I've definitely included the script (it's visible in the Script Documents shown in VS during debugging run-time and in Firebug's script tab), and in the order of dependency (jquery <- jquery-ui <- my script).

The scripts available on the page are:

  • modernizr
  • jquery 1.4.2
  • jquery ui 1.8.6
  • my script using .draggable()
  • another copy of jquery being imported by someone else's control

Could there be a conflict between other li开发者_如何学Gobraries?

It's been tested in an empty project that doesn't include other libraries and it works.

How best to diagnose/resolve this?


It was the duplicate copy of JQuery.

It must've replaced the JQuery object in the DOM, and destroyed the JQuery-UI extension before the $(document).ready handler was run.


I was having the same issue here. I use a slider module that was corrupting Manage buttons. So the solution I found out (based on StuperUser answer) was call jQuery and jQuery UI in the module's header.

I don't know if the solution is good - it shouldn't be. If anyone that had the same issue, please share solution :)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜