1
我需要在Dreamweaver中进行大量的搜索和替换。目前,我有这样的HTML:正则表达式搜索和替换
data-number="10" data-type="normal"
,我需要得到这个数据到一个id:
id="normal-10"
有没有办法做到这一点使用正则表达式搜索和替换?
我需要在Dreamweaver中进行大量的搜索和替换。目前,我有这样的HTML:正则表达式搜索和替换
data-number="10" data-type="normal"
,我需要得到这个数据到一个id:
id="normal-10"
有没有办法做到这一点使用正则表达式搜索和替换?
替换此:
data-number="([^"]+)" data-type="([^"]+)"
与此:
id="$2-$1"
每组引号之间的部分相匹配,并$n
指组号。
你可以使用这个表达式:
data-number="(\d*)" data-type="normal"
而对于更换现场:
id="normal-$1"