Communities for your favorite technologies. Explore all Collectives
Stack Overflow for Teams is now called Stack Internal. Bring the best of human thought and AI automation together at your work.
Bring the best of human thought and AI automation together at your work. Learn more
Find centralized, trusted content and collaborate around the technologies you use most.
Stack Internal
Knowledge at work
Bring the best of human thought and AI automation together at your work.
This is an html part I'd like to parse:
<b id="finish_kar_cri">0x61496a395F549XzxzxZ</b>
How can I replace this part:
0x61496a395F549XzxzxZ
to
8472875
Thanks in advance.
document.getElementById("finish_kar_cri").innerText = "*****";
function change(){ document.getElementById("finish_kar_cri").innerHTML = "8472875"; }
<b id="finish_kar_cri">0x61496a395F549XzxzxZ</b> <button onclick='change()'>Change Text</button>
Add a comment
function change() { var myelem = $('#finish_kar_cri'); myelem.text('8472875'); }
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <b id="finish_kar_cri">0x61496a395F549XzxzxZ</b> <button onclick='change()'>Change Text</button>
Start asking to get answers
Find the answer to your question by asking.
Explore related questions
See similar questions with these tags.
document.getElementById("finish_kar_cri").innerText = "*****";