If you have the need to create a custom widget area in WordPress for a section of your site which doesn’t already have a widget area, the steps are pretty simple.
First, create the widget areas in your functions.php file:
if ( function_exists('register_sidebar') )
register_sidebar(array(
‘name’ => ‘Sidebar 1’,
‘id’ => ‘sidebar1’,
‘description’ => ‘Some description text here’,
‘before_widget’ => ‘<div class=”sidebar-one”>’,
‘after_widget’ => ‘</div>’,
‘before_title’ => ‘<h3 class=”widget-title”>’
‘after_title’ => ‘</h3>’
));
register_sidebar(array(
'name' => 'Sidebar 2',
'id' => 'sidebar2',
'description' => 'Some description text here',
'before_widget' => '<div class="sidebar-two">',
'after_widget' => '</div>',
'before_title' => '<h3 class="widget-title">'
'after_title' => '</h3>'
));
Then simply call your custom widget area within the appropriate WordPress template:
<?php
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Sidebar 1') ) :
?>
<?php endif; ?>