I would like to achieve the following URL structure for my site:
mysite/blog/{post-slug} - for all blog posts and
mysite/portfolio/{portfolio-slug} - for all portfolio items
Is this possible?
The only way I found to insert a "/blog/" in the URL is via custom permalink structure - but unfortunately, this structure is also applied to portfolio items, changing their URL to: mysite/blog/portfolio/{portfolio-slug}
Any advice or helpful suggestion is most welcome. Thanks!
thanks for your reply and support! Worked perfectly! :) For the record: after changing the .PHP file, you still need to rebuild the permalink structure (otherwise you get 404s for the new URLs) - might be a handy tip for others in similar situations. Thanks again!
Hi there!
I would like to achieve the following URL structure for my site:
Is this possible?
The only way I found to insert a "/blog/" in the URL is via custom permalink structure - but unfortunately, this structure is also applied to portfolio items, changing their URL to: mysite/blog/portfolio/{portfolio-slug}
Any advice or helpful suggestion is most welcome. Thanks!
Kind regards, Daniel
Hi Daniel,
Can you try adding this code to the functions.php of the child theme:
Best regards,
Laborator Team
Hi Art,
thanks for your reply and support! Worked perfectly! :) For the record: after changing the .PHP file, you still need to rebuild the permalink structure (otherwise you get 404s for the new URLs) - might be a handy tip for others in similar situations. Thanks again!
Kind regards, Daniel
Hi Daniel,
You're right as I forgot to mention that you need to re-save the changes, happy to hear that it worked.
Have a great day, I will set this ticket as solved from here!
Best regards,
Laborator Team