方法:removeAttribute(被删除属性)
如:document.getElementsByTagName("H1")[0].removeAttribute("style");
详见:HTML DOM removeAttribute() 方法 | 菜鸟教程
更多推荐
js 删除HTML标签指定的属性
方法:removeAttribute(被删除属性)
如:document.getElementsByTagName("H1")[0].removeAttribute("style");
详见:HTML DOM removeAttribute() 方法 | 菜鸟教程
更多推荐
js 删除HTML标签指定的属性
发布评论