I have a JS function below that generates an href which includes the JQ Mobile data-role=”button” class. This is being ignored by the browser – can anyone suggest a solution.
<script>
function showCONTACTDETAIL() {
var tryouttext='<a href="" data-role="button">hey this is cool</a>';
jQuery('#tryout').html(tryouttext);
}
$('#cusdetail').live('pageshow', function () { showCONTACTDETAIL(); });
</script>
Use
You need to trigger the
createevent on a container, to make all dynamic content in that container to get styled..Quoting from http://jquerymobile.com/blog/2011/07/22/jquery-mobile-team-update-week-of-july-18th/