So I was able to create the widgets and have them show up in my copyright footer but both widgets are both centered. How can I go about making 1 widget in the center and 1 widget in the right side?
This is the code I am using:
CSS:
.widgetcopyrightcenter {
float: center;
margin-top: 5px;
margin-bottom: 0px;
margin-right: 1px;
display: block;
font-size: 10.5px;
}
.widgetcopyrightright {
float: right;
margin-top: 5px;
margin-bottom: 0px;
margin-right: 0px;
display: block;
font-size: 10.5px;
}
Footer.php:
<?php if ( ! dynamic_sidebar( 'Copyright Footer Center' ) ) : ?>
<?php endif; // end extra-widget area ?>
<?php if ( ! dynamic_sidebar( 'Copyright Footer Right' ) ) : ?>
<?php endif; // end extra-widget area ?>
Functions.php:
// Add a widget.
if (function_exists('register_sidebar')) {
register_sidebar(array(
'name' => 'Copyright Footer Center',
'id' => 'extra-widget2',
'description' => 'Copyright Footer Center',
'before_widget' => '<div id="%1$s" class="widget %2$s">',
'after_widget' => '</div>',
'before_title' => '<p>',
'after_title' => '</p>'
));
}
// Place the widget in copyright footer
add_filter ('__row', 'add_my_widget2');
function add_my_widget2() {
if (function_exists('dynamic_sidebar')) {
dynamic_sidebar('Copyright Footer Center');
}
}
// Add a widget.
if (function_exists('register_sidebar')) {
register_sidebar(array(
'name' => 'Copyright Footer Right',
'id' => 'extra-widget3',
'description' => 'Copyright Footer Right',
'before_widget' => '<div id="%1$s" class="widget %2$s">',
'after_widget' => '</div>',
'before_title' => '<p>',
'after_title' => '</p>'
));
}
// Place the widget in copyright footer
add_filter ('add_my_widget3');
function add_my_widget3() {
if (function_exists('dynamic_sidebar')) {
dynamic_sidebar('Copyright Footer Right');
}
}