Here i finished it for you and this way works, because u get an htmlObject element or input element here you should do it object.id or value or whatever u want to get and than use it later…
function EditTableCell(a)
{
var Myp= document.getElementById(a);
var nam=Myp.textContent;
var newHTML='<p id="'+a+'"><input size="35" type="text" name="edit'+a+'" id="edit'+a+'" value="'+nam+'" /><input id="'+a+'" type="button" value="Change" onclick="document.AirportsForm.promena.value=document.AirportsForm.edit'+a+'.value;return subb(this);"/></p>';
Myp.innerHTML = newHTML;
Myp.onclick=null;
}
function subb(b)
{
document.AirportsForm.kod.value=b.id;
document.AirportsForm.submit();
}
0
solved I want to send a value to hidden element from javascript [closed]