Is it possible to use this plugin only on specific subpages?
-
Hello, I’d like to use this plugin only on several specific subpages and on the rest of the site use default WP permalinks. More specifically, I want o use it only for children of one or two parent pages.
Is this possible and how to do this?
Looking at the docs, the filter ‘custom_permalinks_exclude_posts’ might be the solution, right? Maybe something like this:?
function yasglobal_exclude_posts( $post ) {
if ( 1111 === $post->post_parent; ) {
return false;
}
return true;
}
add_filter( 'custom_permalinks_exclude_posts', 'yasglobal_exclude_posts' );But as I understad, this only removes the UI from the post detail, it doesn’t stop the plugin from rendering once changed permalink, am I correct? If there are some changes to the permalinks already made, I have to remove them from the custom permalinks list, right?
Is it possible to remove the whole functionality of the plugin for the specific pages (or vice versa, enable it only for specific pages)?
Not sure if I should use the filter ‘custom_permalinks_avoid_redirect’. I’ve tried to use it, but it didn’t seem to change anything.
Thanks for your reply.
- The topic ‘Is it possible to use this plugin only on specific subpages?’ is closed to new replies.