• Resolved champdor

    (@champdor)


    Hi there,

    I have a problem. A build a big site where the News are in the root of the site (/hirek) but the Blog part is on the third tier of the menu structure. So in Settings > Permalinks I gave the posts base as /tevekenysegeink/tanoda/blog.

    Now if I click on a News category then the News category archive page gets the permalink of /tevekenysegeink/tanoda/blog/news-category/hirek/ instead of /news-category/hirek.

    How could I change that? Although I can make without News categories but it would be better to make it work.

    Best regards,
    Peter

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello @champdor

    Do you want URL Of Archive page like this? : /tevekenysegeink/tanoda/blog/hirek/

    instead of /tevekenysegeink/tanoda/blog/news-category/hirek/ Right ?

    Please let us know your thoughts.

    Thanks & regards.

    Thread Starter champdor

    (@champdor)

    Hi,

    No, the confusion is that I gave “hirek” category to news but they are on /hirek as base page. I change to English for better understanding:

    News are on “/our-news” page. I will use two or three categories for news like “our-acheivements” and “regular-news”. The blog posts’ base URL is “/our-work/school/blog”. So blog is not a first level menu item.

    The problem is that if I click on a news category in meta I want a page like “/our-news/regular-news” or “/our-news/our-achievements” but I don’t get it. Instead I get a page like “/our-work/school/blog/category/regular-news”.

    So the problem is that somehow blog posts archives and news categories archives both gets the BLOG base URL. Which is not good.

    The question is can we do anything to separate the news CPT archives from the blog archives? Or did I do something to mix them?

    The permalink settings are these: https://www.screencast.com/t/BK1mbG8Kc

    Best regards,
    Peter

    ps. If I thank harder maybe it’s not achieveable because there is no option is permalinks for news base URL. Should I opt for a CPT and make the archive pages myself?

    Thread Starter champdor

    (@champdor)

    I read about the problem. I found a free plugin called Custom Post Type Permalinks with which I could change the base URL of news post type. But I don’t need a whole plugin, it would be better if you could provide a snippet for functions.php to set the permalink base for news. Do you have such code?

    Best regards,
    Champdor

    Hello

    Please use following steps

    1. go to plugin folder -> includes -> sp-news-post-type.php line no 68 Replace line 'rewrite' => array( 'slug' => 'news-category' ), BY 'rewrite' => array( 'slug' => 'blog' ),

    2. Admin panel -> settings -> Permalinks -> custom structure -> Add this /%category%/%postname%/

    Please check and let us know if there is anything.

    Thanks and Regards.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘News Cat. Archive gets Posts Custom Structure base :(’ is closed to new replies.