Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
Created·2022-01-27 10:00
Flavor·PCRE2 (PHP)

/
(?<DAY>\d?\d)(?<SEPARATOR>[-.\/])(?<MONTH>\d\d)(\k<SEPARATOR>)(?<YEAR>\d{4})
/
gm
Open regex in editor

Description

This regex allows to match date format with the same separators

Submitted by Cymon