This repository has been archived on 2020-05-08. You can view files and clone it, but cannot push or open issues or pull requests.
understrap/sidebar-templates/sidebar-right.php

28 lines
657 B
PHP
Raw Permalink Normal View History

<?php
/**
2016-11-05 12:35:33 +00:00
* The right sidebar containing the main widget area.
*
* @package understrap
*/
2018-09-10 21:59:04 +00:00
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
if ( ! is_active_sidebar( 'right-sidebar' ) ) {
return;
}
2016-11-05 12:35:33 +00:00
// when both sidebars turned on reduce col size to 3 from 4.
$sidebar_pos = get_theme_mod( 'understrap_sidebar_position' );
?>
<?php if ( 'both' === $sidebar_pos ) : ?>
2018-11-18 22:59:06 +00:00
<div class="col-md-3 widget-area" id="right-sidebar" role="complementary">
<?php else : ?>
<div class="col-md-4 widget-area" id="right-sidebar" role="complementary">
<?php endif; ?>
<?php dynamic_sidebar( 'right-sidebar' ); ?>
</div><!-- #right-sidebar -->