jquery动态删除标签

 

 

 

  $("script").each(function(){//删除  js.stripe.com/v3  脚本
      if($(this).attr("src") && $(this).attr("src").indexOf('js.stripe.com/v3') >= 0){
        $(this).remove();//删除该标签
      }
    });
    $("iframe").each(function(){//删除  js.stripe.com/v3脚本加载出来的 iframe标签
      if($(this).attr("src") && $(this).attr("src").indexOf('js.stripe.com/v3') >= 0){
        $(this).remove();//删除该标签
      }
    });

.

posted @ 2020-08-06 15:14  古墩古墩  Views(980)  Comments(0Edit  收藏  举报