[resolved] How to change the Archive to be shown in Grid style (8 posts)

  1. HawkEye of Manhattan
    Posted 2 years ago #

    Hello, I am using the Themolio theme. I would like to change the Archive view to be also in Grid like it is in the index page. I have uploaded for some help please the 2 theme files responsible for the Archive & Grid Index page.
    Please what can I change to have the Archive page be in grid style like the Index is?

    Archive page file: http://pastebin.com/pdGkSSNG
    Grid Style index page: http://pastebin.com/ZWeaANHi

    Thank you very much for your help and time, truly appreciate it. I tried on my own but couldn't figure it out.

  2. HawkEye of Manhattan
    Posted 2 years ago #

    Could anyone please help, I have really modified the theme to drop it from this thing holding me back :(
    Any help is greatly appreciated..

  3. WPyogi
    Forum Moderator
    Posted 2 years ago #

    Have you tried posting on the developer's site -- it looks like he answers questions fairly quickly:


    EDIT -- looks like you may have asked there a couple of days ago...

  4. HawkEye of Manhattan
    Posted 2 years ago #

    Indeed no reply from there, have also e-mailed them. So far no response, that is why I am coming to the community for some friendly help.

    [ allow more time for replies - http://codex.wordpress.org/Forum_Welcome#No_Bumping ]

  5. WPyogi
    Forum Moderator
    Posted 2 years ago #

    I'm guessing that no one here is very familiar with that theme...and that's it's a weekend. Assuming that it's not an option in the theme, it's conceivable that you could create a custom template to do what you want. But you'd have to get into the php -- and unfortunately, that's not my strong point -- someday I hope!

  6. alchymyth
    Forum Moderator
    Posted 2 years ago #

    generally, compare the code of the direct loop in archive.php with the code in index.php (the bit between 'while(have_posts()):the_post();' and 'endwhile') and copy it from index.php into archive.php (make a backup copy first).

    however, depending on your used settings in the theme's options, there will be a lot of formatting to be adapted.

    please post a link to your site to illustrate what you have so far.

  7. HawkEye of Manhattan
    Posted 2 years ago #

    I figured it out after many many tireless hours :(
    The Themolio theme support is very bad in fact it sucks sadly.
    Thank you all for your contributions.

  8. gear4me
    Posted 2 years ago #

    This code can solve your problem:

    <div class="container<?php echo $containerclass; ?>">
        <?php if(have_posts()): ?>
            <?php while(have_posts()) : the_post(); ?>
                <?php if($themolio_options['blog_style'] == 'grid' and !$themolio_is_mobile): ?>
    <?php if($themolio_options['grid_layout'] == 'left-right'): ?>
                        <?php get_template_part('content', 'grid-top-bottom'); ?>
    <?php elseif($themolio_options['grid_layout'] == 'top-bottom'): ?>
                         <?php get_template_part('content', 'grid-top-bottom'); ?>

    This piece of code must be inserted after:

    <?php if(($themolio_options['blog_style'] == 'grid' and !$themolio_options['show_sidebar_grid']) or $themolio_is_mobile) {
        $containerclass = ' fullcontainer';
    } else {
        $containerclass = '';
    } ?>

    Look how it works on my site

Topic Closed

This topic has been closed to new replies.

About this Topic