get_search_query

get_search_query

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.7.2

apply_filters('get_search_query') is found 1 times:

  • /wp-includes/general-template.php line 4336
    4332
    4333
    4334
    4335
    4336
    4337
    4338
    4339
    4340
    4341
    4342
         * @since 2.3.0
         *
         * @param mixed $search Contents of the search query variable.
         */
        $query = apply_filters( 'get_search_query', get_query_var( 's' ) );
     
        if ( $escaped ) {
            $query = esc_attr( $query );
        }
        return $query;
    }

See this hook used in plugins: