Onblur problems

A

Arjen

Hi I got a few <spans> wich, onclick, are replaced by textfields that
should update onBlur. This works great on all but one occasion .. when I
click text1 it gets replaced with a textfield then when I click text2,
text2 gets replaces with the textfield BUT text1 doesn't get updated ..
is there any way to solve this problem ?




function changeQuestion(no,txtval)
{
document.getElementById("cont" + nn + "top").innerHTML = "<input
type='text' id = 'myid' name ='mytext' value='" + txtval + "'
onChange='updateQuestionText(\"" + no + "\")'; >";

<span onclick="Javascript:changeQuestion('1','text1')>text1</span>
<span onclick="Javascript:changeQuestion('2','text2')>text2</span>
}

Arjen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,074
Latest member
StanleyFra

Latest Threads

Top