I am showing a dialog using jquery mobile alpha 4 with ajax, for example:
Inside the succes callback:
success: $j('#wchkdiv').html(msg); $j("#wchkdiv").dialog(); $.mobile.changePage($('#wchkdiv'), 'pop', false, true);
Above the code makes the dialog nicely transition to its appearance when any text on the html page (and not the anchor tag) is clicked on it, with which the javascript binds the click event.
Now in the dialog box there is code:
<form id="gform" name="gform" class="formbody" method="post"> <input class="btns" type="button" onclick="return wchkSubmit(event,'tryAgain');" name="tryAgain" value="Try Again"/> </form>
When the Try Again button is clicked, I have to process it through javascript, which should close the dialog box (by the way, what it needs to do), and the content page that was shown before the dialog box displays now displays again. This means that it should not cause the page to reload, and the dialog should not be part of the browsing history.
It would be another big plus if you could show me how I can make jquery mobile Dialog appear on a part of the screen overlaid on an html page with the html page content darkened or some kind of transparency effect? Dialog currently occupies the entire screen.
source share