[Support request] categories and subcategories problem

Home Forums Support categories and subcategories problem

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1344035
    Joe

    Hi, when creating a post and adding category and subcategory I run into a problem. I tick the boxes for the main category and the subcategory but if I make the parent category the primary category it strips out the subcategory from the url. So instead of the url being blog/learning-to-play/post name it changes to blog/post name.

    #1344336
    David
    Staff
    Customer Support

    Hi there,

    what plugin is it you’re using to provide the Primary Category option ?
    GP doesn’t interfere with permalinks and URL structures, so you may need to look at that plugins documentation – let me know

    #1344366
    Joe

    Hi Dave

    Below you’ll find a list of plugins on the site. I’m not sure but I don’t think any of them specifically provides a Primary Category option. I could be wrong. Do you know?

    Akismet Anti-Spam

    Better Search Replace

    Classic Editor

    Contact Form 7

    Contextual Related Posts

    Cookie Notice

    Elementor

    Elementor Pro

    Envato Elements

    GP Premium

    jQuery Pin It Button for Images

    Optimize Database after Deleting Revisions

    Really Simple CAPTCHA

    Remove Query Strings From Static Resources

    Simple Sitemap

    Smush

    WishList Memberâ„¢

    Yoast SEO

    #1344610
    David
    Staff
    Customer Support

    Its a feature of Yoast:

    https://yoast.com/help/how-to-select-a-primary-category/

    You would need to speak with their support regarding the effect it has on the permalink structure.

    #1344643
    Joe

    Thanks for that David. So Yoast is where the option comes from.

    Reading through their page it looks like I would have to add a piece of code to my theme’s functions.php file.

    So, it looks like this feature only avoids confusion if there are many options to make the primary category.

    I don’t think that this will be a problem with my site, and possibly the way it is set at the moment might be OK. What do you think?

    I have added an image showing how the structure looks in wordpress page editor. The subcategory is indented to the main category which is blog.

    #1344694
    Joe

    Sorry David. Forgot to add image.

    Image of category and subcategory

    #1344793
    Tom
    Lead Developer
    Lead Developer

    I’ve very rarely had to use the primary category feature. The one place I’ve found it useful is on our documentation site (https://docs.generatepress.com). We use it to display/highlight the primary category of an article if it belongs to many.

    Unless you specifically need the primary category feature for something, I would probably just ignore it 🙂

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.