admin管理员组文章数量:1353308
I have a problem using jQuery ui and dialog()
function:
Uncaught TypeError: Object function (a,b){return new e.fn.init(a,b,h)} has no method 'dialog'
I've googled around many people with the same problem solved that issue with a correct inclusion of jQuery library.
This is the header:
And this is the gpf1.js source:
I have a problem using jQuery ui and dialog()
function:
Uncaught TypeError: Object function (a,b){return new e.fn.init(a,b,h)} has no method 'dialog'
I've googled around many people with the same problem solved that issue with a correct inclusion of jQuery library.
This is the header: http://pastebin./e1cTKGK9
And this is the gpf1.js source: http://pastebin./0jXhU503
Share Improve this question edited Jun 8, 2019 at 15:46 Brian Tompsett - 汤莱恩 5,89372 gold badges61 silver badges133 bronze badges asked Dec 25, 2011 at 1:53 LukeLuke 1,84410 gold badges44 silver badges73 bronze badges 1- In the future, please post some code in the question itself (don't rely on external sites). Also: try to narrow down the problem to a specific piece of code, so you don't have to post a "wall of code". Have a look at How to Ask. – Peter-Paul van Gemerden Commented Dec 25, 2011 at 13:49
2 Answers
Reset to default 3In line 48 in your gpf1.js file
$.dialog();
This $.
sign applies the dialog method to the whole jquery element. you should use the dialog method to a DOM element you want like:
$(foo).dialog()
And here's part of the DEMO from jqueryui..
$(function() {
$( "#dialog" ).dialog();
});
</script>
<div class="demo">
<div id="dialog" title="Basic dialog">
<p>This is the default dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p>
</div>
</div>
This can be fixed with the snippet bellow
// http://bugs.jquery./ticket/11921
if(! $.isFunction($.fn.curCSS)) {
$.curCSS = $.css;
$.fn.curCSS = $.fn.css;
var mouseY, lastY = 0;
}
本文标签:
版权声明:本文标题:javascript - jQuery UI - Uncaught TypeError: Object function (a,b){return new e.fn.init(a,b,h)} has no method 'dialog&am 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1743906710a2559656.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论