Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #346491

    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,

    #346821

    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

    • This reply was modified 10 years ago by Elliott.
    #1044299

    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

    #1044846

    Hi unicaweb,

    You can use this code to change the layout just adjust the code accordingly:

    Best regards,
    Victoria

    • This reply was modified 5 years, 11 months ago by Victoria.
Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.