怎么取消所有设置?

来源:4-1 编程挑战

慕粉146

2016-08-11 23:21

怎么取消所有设置

写回答 关注

2回答

  • rooooooottin
    2016-08-12 00:18:53
    var _txt= document.getElementById("txt");
    _txt.removeAttribute("style");
    //或者 _txt.style.cssText="null";


  • 慕粉3812182
    2016-08-11 23:50:11

    div=document.getElementById("div1");

    div.removeAttribute("style");

JavaScript入门篇

JavaScript做为一名Web工程师的必备技术,本教程让您快速入门

738651 学习 · 9561 问题

查看课程

相似问题