1,FF不支持innerText,只支持textContent. 2,判断是否为IE浏览器: if (document.all) { alert("IE"); } else { alert("Not IE"); }