Fotiman - 2:54 pm on Nov 1, 2012 (gmt 0)
Also, avoid using document.write, as it's generally considered bad practice to use it. Instead, use DOM methods to modify values and/or insert new content. birdbrain's example above uses the nodeValue to change the value of an existing node. Other options could include creating a new node and using appendChild or replaceChild to add it to the document.