Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: rest_{$this->taxonomy}_collection_params

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
993            * This filter registers the collection parameter, but does not map the
994            * collection parameter to an internal WP_Term_Query parameter.  Use the
995            * `rest_{$this->taxonomy}_query` filter to set WP_Term_Query parameters.
996            *
997            * @since 4.7.0
998            *
999            * @param array       $query_params JSON Schema-formatted collection parameters.
1000            * @param WP_Taxonomy $taxonomy     Taxonomy object.
1001            */
1002           return apply_filters( "rest_{$this->taxonomy}_collection_params", $query_params, $taxonomy );
1003      }
1004
1005      /**
1006       * Checks that the taxonomy is valid.
1007       *
1008       * @since 4.7.0
1009       * @access protected
1010       *
1011       * @param string $taxonomy Taxonomy to check.