I have a div which has several child s. Example: < 14条回答 谎友^ (楼主) 2020-12-07 10:47 jQuery's empty() function does just that: $('#masterdiv').empty(); clears the master div. $('#masterdiv div').empty(); clears all the child divs, but leaves the master intact. 0 讨论(0) 查看其它14个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复 热议问题
which has several child s. Example: < 14条回答 谎友^ (楼主) 2020-12-07 10:47 jQuery's empty() function does just that: $('#masterdiv').empty(); clears the master div. $('#masterdiv div').empty(); clears all the child divs, but leaves the master intact. 0 讨论(0) 查看其它14个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复 热议问题
s. Example: < 14条回答 谎友^ (楼主) 2020-12-07 10:47 jQuery's empty() function does just that: $('#masterdiv').empty(); clears the master div. $('#masterdiv div').empty(); clears all the child divs, but leaves the master intact. 0 讨论(0) 查看其它14个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复
Example:
<
jQuery's empty() function does just that:
$('#masterdiv').empty();
clears the master div.
div
$('#masterdiv div').empty();
clears all the child divs, but leaves the master intact.