Astra_Breadcrumb_Trail::set_post_taxonomy()
Sets the $post_taxonomy
property. This is an array of post types (key) and taxonomies (value).
Description
The taxonomy’s terms are shown on the singular post view if set.
Return
(void)
Source
File: inc/addons/breadcrumbs/class-astra-breadcrumb-trail.php
protected function set_post_taxonomy() { $defaults = array(); // If post permalink is set to `%postname%`, use the `category` taxonomy. if ( '%postname%' === trim( get_option( 'permalink_structure' ), '/' ) ) { $defaults['post'] = 'category'; } $this->post_taxonomy = apply_filters( 'astra_breadcrumb_trail_post_taxonomy', wp_parse_args( $this->args['post_taxonomy'], $defaults ) ); }
Expand full source code Collapse full source code View on Trac
Changelog
Version | Description |
---|---|
1.0.0 | Introduced. |