Change text in JQM Collapsible without including <span>click to collapse contents</span> text
I am trying to change the heading text of a collapsible, but no matter what I try, it always includes the span text as well.
Here is the enhanced HTML:
- <div data-role='collapsible' class='...'>
- <h4 class='...'>
- <a href='#' class='...'>
- "Some Text"
- <span class='ui-collapsible-heading-status'> click to collapse contents</span>
- ::after
- </a>
- </h4>
- </div>
The selectors I have tried to isolate the "Some Text" so far:
- $("div [data-role^='collapsible'] a:not(':first-child')")
- $("div [data-role^='collapsible'] a:not('span')")
- $("div [data-role^='collapsible'] a:not('.ui-collapsible-heading-status')")
- $("div [data-role^='collapsible'] a:not('span.ui-collapsible-heading-status')")
Is there a selector that will reference "Some Text" without the span text?
TIA (Omar to the rescue again?)