tramite una funzione sto aggiungendo una riga ad uan tabella.
Ad una cella di questa tabella, appendo un campo input che mi permetta di fare semplici operazioni matematiche.
Ho provato cosi:
var td3 = document.createElement("TD")
var sel1 = document.createElement("INPUT")
sel1.setAttribute('name','4_letto_rid')
sel1.setAttribute('value',4+'rid'+liv+num)
sel1.setAttribute('OnChange','document.getElementById("'+4+'rid'+liv+num+'").value = eval(this.value)')
sel1.setAttribute('id',(4+'rid'+liv+num))
sel1.setAttribute('size','5')
td3.appendChild(sel1)
con FF funziona con IE no!!
Ad una cella di questa tabella, appendo un campo input che mi permetta di fare semplici operazioni matematiche.
Ho provato cosi:
var td3 = document.createElement("TD")
var sel1 = document.createElement("INPUT")
sel1.setAttribute('name','4_letto_rid')
sel1.setAttribute('value',4+'rid'+liv+num)
sel1.setAttribute('OnChange','document.getElementById("'+4+'rid'+liv+num+'").value = eval(this.value)')
sel1.setAttribute('id',(4+'rid'+liv+num))
sel1.setAttribute('size','5')
td3.appendChild(sel1)
con FF funziona con IE no!!