Split sidebar into two [TechMaish WordPress theme]

Today we can see how to have two sidebars in Techmaish WordPress theme. It’s really easy, Just follow the steps done below,

- Adding new sidebar to the Stylesheet and reducing the existing sidebar width

(Right)Existing sidebar width reduced to 200px from 310px.

#sidebar {
float:right;
font-size:11.7px;
margin-right:0;
margin-top:15px;
padding-right:15px;
width:200px;
}

(Left)New sidebar added to Stylesheet with width 110px.

#sidebar-2 {
float:left;
font-size:11.7px;
margin-right:0;
margin-top:15px;
padding-right:15px;
width:110px;

- Adding new sidebar to functions.php (add the folloring code below //Sidebar )

//Sidebar-2
if ( function_exists(‘register_sidebar’) ) {
register_sidebar(array(
‘name’ => ‘Sidebar-2′,
‘before_widget’ => ‘<div class=”sidebar-widget wide-widget”>’,
‘after_widget’ => ‘</div>’,
‘after_title’ => ‘</h2>’,
));
}

After adding this you must be able to view new sidebar under widget section,

Split sidebar into two [Techmaish WordPress theme]

- Adding new sidebar to Sidebar.php

<div id=”sidebar-2″>
<?php if ( !function_exists(‘dynamic_sidebar’) || !dynamic_sidebar(‘Sidebar-2′) ) : ?><?php endif; ?>
</div>

You theme should look like this,

Split sidebar into two [Techmaish WordPress theme]

If you wish to increase the width of sidebars, you should still edit few lines in style sheet. If you have any doubt comment below.,


Hi, you can follow me at Google + here

Share This Post

Recent Articles

4 Responses to “Split sidebar into two [TechMaish WordPress theme]”

  1. Bilal Ahmad says:

    Thanks for the addition in TechMaish Theme Tutorials. I will add this in the list so that TechMaish Theme users can add the 2nd sidebar easily.

  2. SHEKHAR says:

    I cannot imstall this theme..plz post the step by step process to install it!

Leave a Reply

© 2013 Chaetakadai.com. All rights reserved. · Entries RSS · Comments RSS
Powered by WordPress · and MyNewMachine.com