jquery??? detach ???? ???? ??? ??? ???? ??? ?? ???? ?? ??? ??? ? ??? ???? ???? ???? ??? ?? ??? ? ????. ??? "$(selector)???. .detach() "; ??? ????? ??? ???? ?? ????empty() ???? ??????.

? ????? ?? ??: windows10 ???, jquery3.2.1 ??, Dell G3 ???.
?? ??? ? ?? ??? ???? ??? ??? ???? ??
detach() ???? ???? jquery?? ??? ???? ?????. ?? ?? ???? ???? ?????.
? ??? ??? ??? ???? ???? ??? ?? ??? ? ??? ???.
?: ??? ?? ??? ? ???? ???? ?? ?? ?? Remove() ???? ?????.
?: ??? ??? ???? ????? ?? ??() ???? ?????.
Grammar
$(selector).detach()
??? ??? ????.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>123</title>
<script src="js/jquery.min.js">
</script>
<script>
$(document).ready(function(){
$("button").click(function(){
$("p").detach();
});
});
</script>
</head>
<body>
<p>這是一個(gè)段落。</p>
<p>這是另一個(gè)段落。</p>
<button>移除所有P元素</button>
</body>
</html>
?? ??:

?? ?? ???? ??: jQuery ?? ????
? ??? Jquery?? ?? ??? ???? ??? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!