Created
          January 30, 2012 04:37 
        
      - 
      
- 
        Save elijahmanor/1702566 to your computer and use it in GitHub Desktop. 
    Find the jQuery Bug #3: Problem 
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | <div id="dialog-modal">Hello World</div> | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <link class="jsbin" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1/themes/base/jquery-ui.css" rel="stylesheet" type="text/css" /> | |
| <meta charset=utf-8 /> | |
| <title>JS Bin</title> | |
| <!--[if IE]> | |
| <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> | |
| <![endif]--> | |
| <style> | |
| article, aside, figure, footer, header, hgroup, | |
| menu, nav, section { display: block; } | |
| </style> | |
| </head> | |
| <body> | |
| <div id="dialog-modal">Hello World</div> | |
| <script class="jsbin" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> | |
| <script class="jsbin" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/jquery-ui.min.js"></script> | |
| <script src="https://getfirebug.com/firebug-lite.js"></script> | |
| </body> | |
| </html> | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | var popover = (function( $ ) { | |
| var pub = {}, modal; | |
| pub.init = function() { | |
| modal = $( "#dialog-modal" ); | |
| if ( modal && modal.not( ".ui-dialog-content" ) ) { | |
| console.log( "selection exists, but isn't initialized" ); | |
| modal.dialog({ | |
| height: 140, | |
| modal: true, | |
| autoOpen: false | |
| }); | |
| } | |
| }; | |
| pub.open = function() { | |
| modal.dialog( "open" ); | |
| }; | |
| return pub; | |
| }( jQuery )); | |
| $(function() { | |
| popover.init(); | |
| popover.open(); | |
| }); | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment