Community Patterns

Community Library Entry

0

Regular Expression
Created·2020-06-06 18:58
Flavor·PCRE (Legacy)

/
<if (?'name'\w+)(?'op'[=!<>][=]?)(?'value'.+?)>(?'true'.+?)(?:<else>(?'false'.*))?<\/if>
/
gs
Open regex in editor

Description

Prints a statement if expression evaluates to true, otherwise prints an alternative expression

Submitted by anonymous