yes, agree that I should have figured this out from the doc, but no – I could not 🙁
<div id="jalla">
<span>
<span class="ui-btn-text">
I need this text
<span class="ui-collapsible-heading-status">
click to collapse contents
</span>
</span>
<span>
</div>
How to simply select (and update) the text “I need this text”. This is one of the things I’ve tried:
notWorking = $('.ui-btn-text').text();
Sometimes jQuery is not the best answer. In this case the HTML DOM makes it easier.
Seen in action: http://jsfiddle.net/C7Q6K/
Edit: For older browsers, you could use jQuery to get the
spanitself: