![]() |
VOOZH | about |
jQuery Mobile is a set of HTML5 based user interface systems developed to create responsive content for mobiles, tabs, and desktops. It is built on top of jQuery. In this article, we will be using the jQuery Mobile Popup create event which triggers when the popup is created.
Callback Parameters: The callback function accepts an event parameter of type event and a UI Object. The UI object is empty, it is included for consistency with other events across the jQuery Mobile library.
Syntax:
Initialize the popup with the create callback specified.
$(".selector").popup({
create: function( event, ui ) {
// Your code here
}
});Bind an event listener to the popupcreate event.
$(".selector").on( "popupcreate", function( event, ui ) {} );Parameters: It accepts a callback function that holds two parameters.
CDN Links:
<link rel="stylesheet" href="https://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css" /> <script src="https://code.jquery.com/jquery-2.1.3.js"></script> <script src="https://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.js"></script>
Example: The below example demonstrates the use of Popup create event.
Output:
👁 jQuery Mobile Popup create Event