Easy Tutorial
❮ Jquerymobile Popups Event Pagebeforehide ❯

jQuery Mobile pagebeforeshow Event

jQuery Mobile Events

Example

Display a text message before the page is shown after a transition:


Definition and Usage

The pagebeforeshow event is triggered before the page is shown after a transition.

Related Events:

Note: This event is triggered at the start/stop of each transition page.


Syntax

To trigger the event for all pages in jQuery Mobile:

To trigger the event for a specified page:

Parameter Description
function(event, data) Required. Specifies the function to run when the pagebeforeshow event is triggered. The function includes the following two parameters: Event object - Includes any jQuery event properties (event.target, event.type, etc.). For more information, refer to the jQuery Event Reference. Data object - Contains properties such as prevPage, which returns the previous page of the transition.
page Optional. The page ID that the pagebeforeshow event points to. For internal pages, use #id. For external pages, use externalfile.html.

More Examples

Demo of Related Events

Event Object

Data Object


jQuery Mobile Events

❮ Jquerymobile Popups Event Pagebeforehide ❯