IE里可以使用innerText 和 innerHTML, FF里只能用 innerHTML

IE里读取自定义属性可直接用 id.attrname, FF里只能用 id.getAttribute("attrname")

<a onclick='return false;'> IE中,如果onclick返回false,则不转跳链接。

FF下,继续跳转。如果不想让FF跳转,必须设置 onclick="javascript:void(0);"

 

IE下设置节点内容,可以用 node.innerHtml = "", FF3.X不支持,可用JQuery实现: $(node).html("xxx")

 

posted on 2015-07-02 00:18  五星  阅读(174)  评论(0)    收藏  举报