I'm having problems with what seems to be a simple issue. I want to change / update the button text of a button programmatically. However, after looking trough several different similar questions here on SO I'm still no closer.
I'm using Chrome with jQuery 1.9 and JQM 1.3 Final.
HTML (this block resides inside a grid that belongs to the footer)
<div class="ui-block-b">
<div class="ui-bar ui-bar-e" style="height:40px">
<a href="#" class="footerWishOption footerDeleteWish" data-role="button" data-icon="trash">Slett ønske</a>
</div>
</div>
JS
changeButtonText is a plug-in found here.
// 1. Does not work
$('.footerDeleteWish').changeButtonText("Gjenopprett
ønske");
// 2. Does not work
$('.footerDeleteWish .ui-btn-text').text("Gjenopprett ønske");
$('.footerDeleteWish').refresh();
// 3. Does not work
$('.footerDeleteWish').text("Gjenopprett ønske").refresh();
Update / solution:
As mentioned as an comment in the answer below, the problem was the visibilty of the footer. Even though the footer was created in the DOM, the selector did not find it since it was hidden.