WordPress filter hook
cpfm_environment
Fired by 14 WordPress plugins, running on 159K+ sites between them.
“Filter the shared CPFM environment snapshot.”
How to use cpfm_environment
It's a filter: your callback receives the value, and must return the (changed) value.
Add this to your theme's functions.php or a small custom plugin:
add_filter( 'cpfm_environment', function( $env ) {
// Change $env here.
return $env;
}, 10, 1 );Argument names come from Timeline Widget For Elementor (Elementor Timeline, Vertical & Horizontal Timeline)'s source. Other plugins may pass different values: check the call in the plugin you're targeting below.
14 plugins that fire cpfm_environment
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
Timeline Widget For Elementor (Elementor Timeline, Vertical & Horizontal Timeline)70,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:100 -
Cool Timeline (Horizontal & Vertical Timeline)20,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Events Shortcodes For The Events Calendar10,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Events Widgets For Elementor And The Events Calendar10,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Toolkit for Polylang10,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Timeline Block For Gutenberg9,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:100 -
Event Single Page Builder For The Events Calendar6,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:100 -
AutoPoly5,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Cool Flipbox5,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Linguator3,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Event Countdown for The Events Calendar3,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Events Search & Filter Bar for The Events Calendar3,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101 -
Timeline Module for Divi3,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:100 -
Events Calendar Modules for Divi2,000+ installs
apply_filters( 'cpfm_environment', $env )admin/cpfm-feedback/class-cpfm-environment.php:101
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.