I have this function:
function msj(str) { // display = document.getElementById("txt"); // DOM // nodo = document.createTextNode(str); // display.replaceChild(nodo,display.firstChild); $("#txt").html(str); // jQuery } The message is displayed here:
<div id="txt">Guess the number between 1 and 10</div> Then, I want to display the message into a input text form. Anyone knows how to do it?
Many thanks.