我正在创建一个网站的移动版本并使其工作正常我需要从整个页面的某些标签中删除“样式”属性。
示例:
<div class="gallery-arrows" style="top:85px;"></div><h8 style="top:85px;"><a href="https://twitter.com/TeamTHCRacing" style="color:#ffffff;">THC Racing on Twitter!</a></h8>
我需要:
<div class="gallery-arrows"></div><h8><a href="https://twitter.com/TeamTHCRacing" style="color:#ffffff;">THC Racing on Twitter!</a></h8>
我可以添加一些内容来删除它们吗?像剧本一样?
谢谢!
答案 0 :(得分:0)
使用jquery很简单:
$('div,h8,a').removeAttr("style");