Add right side widget to beauty dots theme for wordpress

The theme beauty dots comes with only one widget support at the footer section of the page. In order to solve this and provide support for the right side area as well, we need to investigate of where the problem occurs.

First we check the file sidebar.php, where we see:

if ( ! dynamic_sidebar( 'sidebar-widget-area' ) ) 

which means that the theme expects a dynamic sidebar, but for some reason it doesn’t show up. The next step is to check the file functions.php and there we see:

register_sidebar( array(
		'name' => __( 'Footer Widget Area' ),
		'id' => 'footer-widget-area',
		'description' => __( 'The footer widget area' ),
		'before_widget' => '',
		'after_widget' => '',
		'before_title' => '',
		'after_title' => '',
	) );

The ‘sidebar-widget-area’ is not mentioned anywhere in the file, so what is needed is to register the ‘sidebar-widget-area’ as well. So just above of the previous function we add:

register_sidebar( array(
		'name' => __( 'Right Widget Area' ),
		'id' => 'sidebar-widget-area',
		'description' => __( 'The right widget area' ),
		'before_widget' => '',
		'after_widget' => '',
		'before_title' => '',
		'after_title' => '',
	) );

Now go at your widget menu and there you will see the right widget, where you can customize it.

Keep in mind that if you want to change the id, you have to do that in both files: sidebar.php and functions.php

This entry was posted in Howto, Solutions and tagged , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>