Hey guys, thanks for a great theme!
I’m about to set up a blog portal using Enfold. Since each category in the blog portal will use its own layout I’m trying to make category templates. My idea is that the category templates will show layouts depending on which category the post is being posted in. Is that possible?
I have followed this guide but can’t get it to work with the Enfold framework:
http://www.wpbeginner.com/wp-themes/how-to-create-category-templates-in-wordpress/
Regards,
Hey razhimself!
In your theme folder (or child theme) create a copy of this file, /enfold/archive.php, and rename it to category-slug.php and then edit the file and find line 33 which should look like this.
$avia_config['blog_style'] = apply_filters('avf_blog_style', avia_get_option('blog_style','multi-big'), 'archive');
Change it to this,
$avia_config['blog_style'] = 'blog-grid';
This will change the layout for whatever category slug your using in the filename. You can change the layout to any of these.
blog-grid
single-big
single-small
multi-small
multi-big
Cheers!
Elliott
Hello I try to change blog layout for tag.pho using
$avia_config[‘blog_style’] = apply_filters(‘avf_blog_style’, avia_get_option(‘blog_style’,’multi-big’), ‘tag’);
if($avia_config[‘blog_style’] == ‘blog-grid’)
To
$avia_config[‘blog_style’] = apply_filters(‘avf_blog_style’, avia_get_option(‘blog_style’,’multi-big’), ‘tag’);
if($avia_config[‘blog_style’] == ‘single-small’)
But don not work
Hi unicaweb,
You can use this code to change the layout just adjust the code accordingly:
Best regards,
Victoria