我需要删除XML文件中的标签(大约1000)。我试过用jQuery,但没有成功:
<html>
<!--jquery app removes specific <t2_patch ...>-tag -->
<script src="http://code.jquery.com/jquery-latest.min.js"></script>
</head>
<body>
<button>Kill t2_patch-tags </button>
<script>
$("button").click(function() {
$('/home/dan/series14AreaListOnly.xml').remove('t2_patch');
});
</script>
</body>
</html>
我的目标是删除300MB大型XML文件中的t_patch标签。这种做法到目前为止还没有确定,还是我完全错了。我如何保存更改? (因为remove()函数实际上不会直接在xml文件上删除任何内容?)。
预先感谢任何提示与问候
丹尼亚尔