Regular Expressions 101

Community Patterns

Community Library Entry

1

Regular Expression
PCRE2 (PHP >=7.3)

/
((?<!gf_)apply_filters|do_action).*?\( ?('|")(.*?)('|").*
/
gm

Description

This will pluck out any do_action or apply_filters name in your code. Useful if you want to see what actions or filters have been added or deprecated between codebases, etc.

Submitted by olie480 - 2 years ago