Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Error: cannot call methods on dialog prior to initialization; attempted to call method 'close'.
- jquery-latest.js (line 507)
- <!doctype html>
- <html lang="en">
- <head>
- <meta charset="utf-8" />
- <title>jQuery UI Dialog</title>
- <script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script>
- <link type="text/css" href="http://code.jquery.com/ui/1.9.0/themes/base/jquery-ui.css" rel="stylesheet" />
- <script src="http://code.jquery.com/ui/1.9.0/jquery-ui.js" type="text/javascript"></script>
- <script>
- $(function() {
- $("#open").click(function(){$("#dialog").dialog('open');return false;});
- $( "#dialog" ).dialog({
- modal: true,
- autoOpen : false,
- buttons: {
- Ok: function() {
- $( this ).dialog( "close" );
- }
- }
- });
- });
- </script>
- </head>
- <body>
- <button id="open">Click</button>
- <div id="dialog" title="What ever"></div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement