1

So another regex question:

say i have this string <p> < Hello World > </p>. And I wanted to remove the inner <>, but not the p-tags.

How would I go about making a regex that matches < or > only when they have a space on both sides?

Thanks alot, Erwin

4

1 回答 1

2

对Rubular的快速访问给了我们这个答案:

string.match(\s[<>]\s)
于 2013-01-30T22:38:51.770 回答