WordPress action hook
ct_parse_query
Fired by 5 WordPress plugins, running on 16K+ sites between them.
“Fires after the main query vars have been parsed.”
How to use ct_parse_query
It's an action: your callback runs at that point. Nothing needs to be returned.
Add this to your theme's functions.php or a small custom plugin:
add_action( 'ct_parse_query', function( $arg1 ) {
// Your code runs here.
}, 10, 1 );Argument names come from GamiPress's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
5 plugins that fire ct_parse_query
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
GamiPress10,000+ installs
do_action_ref_array( 'ct_parse_query', array( &$this ) )libraries/ct/includes/class-ct-query.php:780 -
AutomatorWP6,000+ installs
do_action_ref_array( 'ct_parse_query', array( &$this ) )libraries/ct/includes/class-ct-query.php:780 -
ShortLinks Pro100+ installs
do_action_ref_array( 'ct_parse_query', array( &$this ) )libraries/ct/includes/class-ct-query.php:780 -
BBForms20+ installs
do_action_ref_array( 'ct_parse_query', array( &$this ) )libraries/ct/includes/class-ct-query.php:780 -
WhatAvatar20+ installs
do_action_ref_array( 'ct_parse_query', array( &$this ) )libraries/ct/includes/class-ct-query.php:780
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.