美文网首页
jQuery使用小节

jQuery使用小节

作者: 三米板 | 来源:发表于2020-04-18 22:19 被阅读0次

更改某个元素的onClick事件

$(obj).parents("td").find("#title-label").attr('onclick','').click(eval(function(){
    article_examination(obj,title, id , config.res_status.normal);
        //article_examination 就是要替换的方法,再点击时就会执行新的方法。
}));

jQuery删除子元素:

$(obj).parents("tr").find(".td-manage").children()[1].remove();
//删除了找到的第2个子元素

相关文章

网友评论

      本文标题:jQuery使用小节

      本文链接:https://www.haomeiwen.com/subject/dxyzvhtx.html