Regular Expressions 101

Community Patterns

syntaxic equation check

1

Regular Expression
PCRE (PHP <7.3)

/
([+\-*^]\s*[+\-*^]|[xX]\s*[xX])
/
g

Description

check if two operator follow and if two [xX] follow. You can combine this with https://regex101.com/r/qT7fO0/1

Submitted by Kerosene2000 - 9 years ago