jQuery Remove style attributes from ALL elements

前端 未结 7 548
挽巷
挽巷 2020-12-29 07:52

I know how to remove attribute from a single element, there are already some posts about that:

$(\"div.preview\").removeAttr(\"style\");

Th

7条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-29 08:18

    Try doing this

    $("#frameDemo").contents().find("#div_id").parent('div').removeAttr('onclick');
    $("#frameDemo").contents().find("#div_id").children('div').removeAttr('onclick');
    

提交回复
热议问题