JSFiddle - React, Tailwind, and code Playground
by leongaban
HTML
<p>This is in the URL</p>
<span id="text">#!/intro/inbox</span>
<div id="anothertext"></div>
<p>^ Needs to change #! to m</p>
CSS
body { font-family: Arial; }
p {
margin: 20px 0;
}
#anothertext {
color: red;
}
JavaScript
var value = $("#text").text(); // value = 9.61 use $("#text").text() if you are not on select box...
//alert(value);
value = value.replace("#!", "m"); // value = 9:61
// can then use it as
$("#anothertext").text(value);