Support » Plugin: Post Types Unlimited » Page for a CPT Archive

  • Resolved Naresh

    (@nareshrathore)


    Hello AJ,

    I hope you’re doing well.

    I have another question and perhaps an easier one for you. I created a custom post type ‘theme’ so my default archive page ends with the slug theme. e.g. /theme/

    Is there a possibility to rewrite this slug /theme/ to plural /themes/ for my archive? I know there is a nice feature in your plugin which allows us to rewrite the slug but I want my single custom post page to have singular slug name like /theme/custom-post-slug/.

    Thank you in advance.

    regards,
    Naresh

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author wpexplorer

    (@wpexplorer)

    Hi Naresh,

    Unfortunately there is no built-in way in WordPress to do this and all the included options are based on available options for the register_post_type core WP function.

    And I’m honestly not sure what code you could use to customize the post type archive slug (if even possible).

    What I usually do in cases like this is simply disable the automatic archive and then you can create a standard page to display the items with whatever slug you want. This is what we do for our Total theme demos and recommend to customers as it’s the easiest method. Sample video: https://a.cl.ly/eDuyOzEq

    Perhaps the theme you are using or whatever plugins you have access to will allow you to do something similar (use a standard page to display your items and disable the auto archive).

    Hope that helps!

    – AJ

    Thread Starter Naresh

    (@nareshrathore)

    Good morning, AJ.

    That exactly was my first option.

    I tried to use the Kadence Block Pro for displaying my custom post archive but I don’t see the options to select my custom post type when using their Post or Post Grid blocks.

    I’ve raised the issue with Kadence support team and will see what they can do.

    The last option for me is to play with the php template. At least, I can display my custom posts, but when I last checked, the paging was broken. I will take a look further if Kadence dont solve my problem.

    On another note, I’m enjoying your support more. 😉

    Thanks for the efforts you put it in for us. I really appreciate it.

    regards,
    Naresh

    Thread Starter Naresh

    (@nareshrathore)

    I figured out the problem.

    In fact, I had to enable this option under plugin’s settings.
    Show in Rest API (enables Gutenberg)

    Thank you!

    Plugin Author wpexplorer

    (@wpexplorer)

    Awesome! Glad there was an easy solution and thanks for letting me know how to fix the issue. If anyone else has the same problem, hopefully they’ll bump into this thread 😉

    – AJ

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