Custom taxonomies base permalink fix
-
Please, add this code to your /includes/class-auto-hierarchic-category-menu.php file. Line 226:
else{ global $wp_rewrite; $termlink = $wp_rewrite->get_extra_permastruct( $attr[ 'taxonomy' ] ); $link_sub = str_replace( "/%{$attr[ 'taxonomy' ]}%", '', $termlink ); }
This code add the base permalink to custom taxonomies. Tested and working.
And fix line 249:
$link=$slug.'/'.$category->slug.($params['linkget']?'?'.$params['linkget']:'');
Or add a new option to your shortcode to use the trailing slash or not. Not all websites use the trailing slash. We never use it.
Best regards.
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘Custom taxonomies base permalink fix’ is closed to new replies.