I have some HTML:
<label>Search:
<input id="search-box" type="text"/>
</label>
If I want to change the words "Search:" to "Quick Search:", how can I select just the "Search:" text using jQuery/JS?
I have tried html()
, text()
, and other various jQuery methods. My goal is to NOT have to copy the input box and then append it after. Is it possible?
P.S. I know I can use the prepend()
function, but my goal here is to replace that text entirely, and I'd like to know how to do this in the future as well.
Thanks a bunch.