Regular Expressions 101

Community Library Entry

3

Regular Expression
PCRE (PHP <7.3)

/
(?(DEFINE) (?<exprs> (?&expr)(\s+(?&bool)\s+((?&expr)|\(\s*(?&exprs)\s*\)))* ) (?<expr> (?&valleft)\s?(?&comp)\s?(?&valright) ) (?<comp> ((!=)|(==)|(<=)|(>=)|(<)|(>)){1} ) (?<valleft> (?&not)[\w\.]+ ) (?<valright> [\w\.]+ ) (?<bool> (and|or) ) (?<not> (not\s+)?) ) (?&exprs)
/
xmi

Description

comapre simbols used just !=, ==, <=, >=, <, > beacose of task keyword "not" can be used only before leftside value beacose of task

Submitted by Ilya Filisteev - 9 years ago