String.prototype.trim = function() {return this.replace(/^\s+|\s+$/g,"");};
String.prototype.ltrim = function() {return this.replace(/^\s+/,"");};
String.prototype.rtrim = function() {return this.replace(/\s+$/,"");};
$(document).ready(function() {$('.errormessage').jqm({modal:true}); $('.termsmessage').jqm({modal:true}); $('.privacymessage').jqm({modal:true});});	
function showPrivacyPolicy() {$('.privacymessage').jqmShow(); $('#jqmContent3').attr('src', '/privacy'); }
function showTermsAndConditions() {$('.termsmessage').jqmShow(); $('#jqmContent1').attr('src', '/termspopup'); }
function displayError(msg) {$('.throbber').jqmHide(); document.getElementById('messagetext').innerHTML = msg; $('.errormessage').jqmShow();}

