diff options
Diffstat (limited to 'proto.js')
-rw-r--r-- | proto.js | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -208,13 +208,15 @@ try { } } else if(cmd == "update") { - var title = msg[3]; - //var task = document.getElementById(createId(observeid, id)); - var txtdiv = document.getElementById(createId(observeid, id) + "_txt"); - txtdiv.removeChild(txtdiv.firstChild); - - var txt = document.createTextNode(title); - txtdiv.appendChild(txt); + var name = msg[3]; + var value = msg[4]; + if(name == "title") { + var txtdiv = document.getElementById(createId(observeid, id) + "_txt"); + txtdiv.removeChild(txtdiv.firstChild); + + var txt = document.createTextNode(value); + txtdiv.appendChild(txt); + } } f++; } |