我想匹配两个字符串之间的正则表达式。
输入文本是这样的:
Back to previous ›
› Send Message
› Add as Buddy
› Add as Favorite
› Block this Person
People who like this (click to upvote)
我想匹配Back to previous >和People who like this (click to upvote)之间的所有内容。
我尝试了最简单的正则表达式,(?<=\ Back\ to\ previous\ ›\ ).*(?=People\ who\ like\ this\ profile\ \(click\ to\ upvote\)\ )
但没有运气。
想法是捕获 2 行\字符串之间的所有内容,即使您捕获的是换行符、制表符、字母数字等。