here is my problem, i call this method and what it does is
post some data on server using jQuery, i want to display page using result i recieve from server
m
try this..
function loginPostData(jsonRequest)
{
$.post("http://localhost:8080/edserve/MobileServlet",
JSON.stringify( jsonRequest),
function(data)
{
var obj = JSON.stringify(data);
//var object = JSON.parse(json_text);
//alert(obj);
alert(obj);
if(data.status=="success")
{
$.mobile.changePage( "#mainMenu"); // main menu div id..
}
else
{
if(data.message=="user not verified")
{
//display verification page
}
if(data.message=="no user exist with this usname")
{
//set focus to username
$("#username").focus();
}
}
}, "json");
}
You can try using the jquery load function for this http://api.jquery.com/load/
try this code
$.mobile.changePage( "#mainMenu", { allowSamePageTransition: true });
and check this link
http://jquerymobile.com/test/docs/api/methods.html