Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jquery mobile - how to use the "error reporting dialog"

when using jquery mobile, and you load an invalid page, an error message is reported elegantly showing loading page failed(then fades out). Check out the attached image.

i want to use this ui to report my own custom error messages and animate them the way its done. any one had any experience doing this?

i would like to report some errors without using dialogs and this method seems appropriate. Can this be done using jquery and if please show the code.enter image description here

like image 230
Sir Lojik Avatar asked Mar 02 '12 01:03

Sir Lojik


1 Answers

In the latest 1.1.0 RC version you can use $.mobile.showPageLoadingMsg to display custom error messages:

// show error message
$.mobile.showPageLoadingMsg( $.mobile.pageLoadErrorMessageTheme, $.mobile.pageLoadErrorMessage, true );

// hide after delay
setTimeout( $.mobile.hidePageLoadingMsg, 1500 );
like image 150
Oiva Eskola Avatar answered Sep 20 '22 13:09

Oiva Eskola