View Full Version : Changing text in FF.

07-13-2005, 06:22 PM
function setText(){
document.getElementById("friend").innerHTML = document.getElementById('friendname').value;
document.getElementById("message").innerHTML = document.getElementById('messageinput').value.replace(/\n/g, '<br />');


works fine in IE, but it FF I get

document.getElementById('friendname') has no properties
friendname is a span where I want the text to change.

07-13-2005, 07:21 PM
mack sure that it has an id

name will only work for getElementById in IE