Sidebar question

Discussion in 'BlogsTrend WordPress Theme' started by faceless4all, Feb 2, 2015.

Thread Status:
Not open for further replies.
  1. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Hi!
    In regards to the sidebar: Can I have a different sidebar on other pages? For example to display different advertisements on specific pages, posts.
    Currently the sidebar is the same on all posts and pages.
    please advise.
    Thank You,
    Have a nice day!
    Jo
     
  2. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello Jo!

    Unfortunately ! this is not possible to have a different sidebar on different pages.
    You have two widget areas primary and secondary. So, please use primary on some pages and secondary on other pages.

    Thanks & Regards
    Pramod
     
  3. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Okay, how do you use primary on some pages, and secondary on other pages? If that can be done, wouldn't that mean you can create different sidebars for different pages?
     
  4. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello !

    I mean to say generally in all themes we have 4 templates to show contact(contact us),blog (blog list),page(every page),single.
    You can use according to you requirement these 2 widget area in all 4 templates.

    Thanks
    Pramod
    inkthemes.com
     
  5. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Good Day Pramod!

    What I was hoping to do was place a few ads on homepage sidebar, and then a few other ads (different from homepage ads) on all other pages/posts sidebar

    If I place a text widget in primary widget area, this will show on all pages/posts etc., is that correct?
    If I place a text widget in secondary widget area, it should not show in homepage, but will show in all other pages/posts, is that correct?

    I need to know before I set up advertising and promotion on the site.

    Thank You.
    Jo
     
  6. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello Jo !

    You can use primary widgets area only for home page and secondary for all other page after code editing given in image.
    Please follow below image

    blogstrend-sidebar-6feb1.png
    blogstrend-sidebar-6feb2.png

    Thanks & Regards
    Pramod
     
  7. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Hi Pramod,

    Thank You! I will look at this and make those changes later today.
    Regards,
    Jo
    Update: I did try to add the codes to change index.php from the second image you provided, but when I check the site after, it shows unexpected error for the ending line (?) which I think was this:

    <!--End Sidebar Wrapper-->
    </div>
    <?php get_footer(); ?>

    Would it be possible for you to copy and paste codes here for this php file, and/or entire file?
    Thanks.
     
  8. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello !


    You have to use this code.

    PHP:
    ?>
    </div>
    <?php get_footer(); ?>
    This will resolve your issue.

    Thanks & Regards
    Pramod
     
  9. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Hi!
    so I should put that code, after this?
    <!--End Sidebar Wrapper-->

    If you have access to the index.php file from the second image above that you posted, Is it possible for you to copy and paste the codes for me here?
    From line 47 to the end line
     
  10. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello !

    Use given code as shown in below image.

    PHP:
        <div class="grid_sub_8 sidebar_wrapper sub_omega">
            <!--Start Sidebar-->
            <?php if (!dynamic_sidebar('primary-widget-area')) : ?>
                <?php get_search_form(); ?>
                <h4>
                    <?php _e('Categories''inkthemes_blogtrend'); ?>
                </h4>
                <ul>
                    <?php wp_list_categories('title_li'); ?>
                </ul>
                <h4>
                    <?php _e('Archives''inkthemes_blogtrend'); ?>
                </h4>
                <ul>
                    <?php wp_get_archives('type=monthly'); ?>
                </ul>
            <?php endif; // end primary widget area
            
    ?>
            <!--End Sidebar-->
        </div>
    blogstrend-sidebar-7-feb1.png

    Thanks & Regards
    Pramod
     
  11. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Hi,
    thanks. I have made the changes, it seems to work but I haven't tested it completely yet.

    I am not sure if this is related to these changes, but I do notice now, that on 'some' pages, there is white space after the very end of footer settings (complete end of page)
    it seems only to be on pages that are ' too short, so when page does not have any content/ text etc.
    or pages that have very little content.

    Any idea why this would be?
     
  12. Pramod

    Pramod Guest

    Joined:
    Aug 8, 2014
    Messages:
    2,847
    Likes Received:
    63
    Hello Jo !

    This depends on content of page So, keep page content approx or nearby equal to the height of sidebar content of your page.

    Thanks & Regards
    Pramod
     
  13. faceless4all

    faceless4all Member

    Joined:
    Aug 19, 2014
    Messages:
    197
    Likes Received:
    1
    Hi Pramod!
    Thank you, everything is good, all works fine.
     
Thread Status:
Not open for further replies.

Share This Page