您的位置:首页 > 其它

关于DOM节点的小记

2016-12-29 09:49 197 查看
.parent()  父节点

.append()  该节点上添加

.before()  该节点之前添加

.remove()  移除节点

append()和before()括号里面是双引号,用于添加元素

 $("#fd_busi_place__own_industry_two").parent().remove(); 

 $("#fd_busi_place__own_industry_two").parent().before("<div class='form-group' style='display: block;'><label class='col-xs-4 input-sm ' style=''>所属行业(二级)</label><input type='text' id='fd_busi_place__enterprise_two1' name='fd_busi_place__enterprise_two1'
style='background-image: none;border: 1px solid #ccc; ' class='col-xs-6 easyui-validatebox input-sm  validatebox-text' data-options='required:false,validType:'length[0,100]' placeholder='' value=''></div>"); 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: