5i365 (我心飞扬)当前离线
上尉
$s = gc b.txt -enc UTF8 -raw $s -match '(?s)<Que K="Pro">(.*?)</Que>' if ($s -match '(?s)<Que K="Pro">(.*?)</Que>') { $x = $matches[0] [xml]$x | Select-Xml -XPath "/Que/Reference" | foreach { $_.node.InnerXML = "" } }复制代码
went 当前离线
少校
TOP
$s -replace '(?<=<Reference)\s+Relative="\.\.\\\.\.(\\.*?)">(.*?)(?=</Reference>)',('>'+'$1')复制代码
$s = gc b.txt -enc UTF8 -raw if ($s -match '(?s)<Que K="Pro">(.*?)</Que>') { [xml]$x = $matches[0] $x | Select-Xml -XPath "/Que/Reference" | foreach { $_.node.InnerXML = "" } $x.save("new.txt") }复制代码
$s -replace '(?<=<Reference>).*?(?=</Reference>)','新数据'复制代码
评分人数
$s -replace '(?<=<Reference>).*?(?=</Reference>)',''复制代码