Regular Expressions 101

Community Patterns

Div content

3

Regular Expression
PCRE (PHP <7.3)

/
<div[^>]*>((?:(?:(?!<div[^>]*>|<\/div>).)+|<div[^>]*>(?1)<\/div>)*)<\/div>
/
isg

Description

no description available

Submitted by mohammadsaleh - 9 years ago