Tagged: Blog
-
AuthorPosts
-
July 10, 2015 at 10:53 pm #471751
Hi,
How can I properly treat “/blog” as a subdirectory and all posts having the category “posts” will be in the /blog subdirectory? I tried using this solution http://www.dvorakdesigns.com/blog/wordpress-permalinks-add-blog-before-blog-posts-and-related-page-urls but all the old posts without the /blog before the name caused redirect issues. As well as the portfolio posts are being treated as blog posts? Please advise. Thanks.
- This topic was modified 9 years, 4 months ago by avwebmaster.
July 12, 2015 at 12:28 pm #472014Hey avwebmaster!
I’m not sure I understand what you are trying to do there, all posts will display on your blog post unless you filter them somehow. Do you only want to show posts which are have the category “posts” attached to them? If you only want to show one category of posts you can use the Blog Posts element.
Cheers!
RikardJuly 12, 2015 at 3:34 pm #472054Hi Richard,
I would like all my blog posts that have the category “blog” reside under http://www.website.com/blog so when you view the posts, it will say http://www.website.com/blog/my-first-post.
Currently, the posts are set up to be on the parent directory. When I tried to add a /blog sub directory using the above approach, all posts obviously threw a page not found error. It also made all the portfolio posts to be under “blog” instead of it’s own category.
Please advise and thanks.
July 13, 2015 at 3:51 pm #472522Hey!
Change line 34 in the /enfold/includes/admin/register-portfolio.php file from this.
'rewrite' => array('slug'=>_x($permalinks['portfolio_permalink_base'],'URL slug','avia_framework'), 'with_front'=>true),
To this.
'rewrite' => array('slug'=>_x($permalinks['portfolio_permalink_base'],'URL slug','avia_framework'), 'with_front'=>false),
And then refresh your permalinks again to remove the /blog/ from the portfolio posts.
Best regards,
ElliottJuly 13, 2015 at 4:33 pm #472541Hi Elliot,
I am using a child-theme. Will this get overwritten everytime I update?
Please see the attached url for the blog. If you click on one of the latest blog posts, the url takes out the /blog.
I would like to keep it everytime a user click on the blog posts.- This reply was modified 9 years, 4 months ago by avwebmaster.
July 14, 2015 at 1:31 pm #473135Hi!
I think you can just make the changes in your permalink setting. Go to Settings->Permalinks->Common Settings and choose “Custom structure”. Write “blog” into the custom field”.
Regards,
AndyJuly 14, 2015 at 6:58 pm #473370Hi Andy,
Thank you. It did add /blog on all the blog posts. I’m not sure if the old blog urls will cause redirect issues.
Also, it added /blog before the portfolio posts.
From: http://www.website.com/portfolio-item-base/post-name/
To: http://www.website.com/blog/portfolio-item-base/post-name/
This caused redirect issues so I had to switch back to the default setting.Please advise if I need to modify the htaccess file for all portfolio-item-base posts to redirect or add /blog before each url.
July 15, 2015 at 3:49 pm #473801Hi!
If you did this, https://kriesi.at/support/topic/proper-way-to-create-blog-subdirectory-and-posts/#post-472522, then it should not be adding it to the portfolio posts.
Make sure to refresh your permalinks after editing the file to see changes.
Best regards,
Elliott- This reply was modified 9 years, 4 months ago by Elliott.
July 16, 2015 at 10:27 pm #474582Hi Elliot,
I am using a child-theme, will it override everytime I update the parent theme?July 17, 2015 at 2:52 pm #474966Follow up please? :) I did modify the register portfolio php file but the old url which we integrated within a marketing / tracking tool renamed the portfolio link. I have to redirect in that case…
I have to double check if the portfolio posts are not adding the /blog url.
- This reply was modified 9 years, 4 months ago by avwebmaster.
July 19, 2015 at 4:50 pm #475408Hi!
You can use this in the child theme’s functions.php file:
add_filter('avf_portfolio_cpt_args', 'avf_portfolio_cpt_args_mod'); function avf_portfolio_cpt_args_mod($args) { $args['rewrite']['with_front'] = false; return $args; }
Best regards,
IsmaelAugust 14, 2015 at 5:09 pm #487840Hi,
The redirect works on blog but older blogs do not redirect or add the “/blog” directory.
Please advise.August 14, 2015 at 6:20 pm #487873Well I had to manually redirect the link provided. But do I make sure all the old blog posts without the /blog/ directory get redirected?
August 14, 2015 at 9:29 pm #488004Hi!
You will need to either create an htaccess file and regirect them or do a 301 redirect whit a plugin.
You can contact one of our Customization Contractors, who will help you out with the process.
http://kriesi.at/contact/customizationLet us know if we could do anything else, regarding our theme
Regards,
BasilisAugust 14, 2015 at 9:39 pm #488010Thank you for your reply! Yes, we will consider that…
BTW, have you worked with Kentico CMS? We have a current CMS running in Kentico and would like to migrate all data to a WP site. But the site will be a forum based site meaning all categories, posts, forum types, users need to be migrated properly. Please advise. Thanks.
August 17, 2015 at 10:45 am #488746Hi!
no, we does not work with that CMS and we does not provide any support about this.
Let us know if you have any questions or issues which are theme related. We are happy to assist you with our themes.
Cheers!
Andy -
AuthorPosts
- You must be logged in to reply to this topic.