Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
PCRE (PHP <7.3)

/
^((?:[a-z][a-z]|[a-z][0-9]|[0-9][a-z])[a-z]?)([0-9]{1,4}[a-z]?)$
/
gi

Description

recognize a flight number define in wikipedia and capture carrier code and flight number.

source

Submitted by anonymous - 8 years ago