Regular Expressions 101

Community Library Entry

0

Regular Expression
PCRE (PHP <7.3)

/
(?=^\s*DETECTORES SELECCIONADOS HABILITADOS).{40}
/
gmi

Description

Find an exact phrase (with each space and character in its own place) only if it is within the first 40 characters of the entire sentence. Useful to search non-standard phrases in log files.

Submitted by RicardoSPimentel - 9 years ago