This repository was archived by the owner on Nov 4, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsidebar-two.php
More file actions
executable file
·41 lines (33 loc) · 1.57 KB
/
sidebar-two.php
File metadata and controls
executable file
·41 lines (33 loc) · 1.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
/**
* The Sidebar 2 for display in the content page.
* Is only called by header.php or footer.php if the sidebar is needed, so no checking is required!
*
* @package Graphene
* @since graphene 1.0
*/
global $hipoul_settings;
?>
<div id="sidebar2">
<?php do_action( 'graphene_before_sidebar2' ); ?>
<?php /* Widgetized sidebar, if supported. */
if ( ! is_front_page() && is_active_sidebar( 'sidebar-two-widget-area' ) ) { // Not home, display normal sidebar if active
dynamic_sidebar( 'sidebar-two-widget-area' );
} elseif (is_front_page() && !$hipoul_settings['alt_home_sidebar'] && is_active_sidebar( 'sidebar-two-widget-area' ) ) { // Home, but alternate sidebar disabled, display normal sidebar if active
dynamic_sidebar( 'sidebar-two-widget-area' );
} elseif (is_front_page() && $hipoul_settings['alt_home_sidebar'] && is_active_sidebar( 'home-sidebar-two-widget-area' ) ) { // Home, alternate sidebar enabled, display alternate sidebar if active
dynamic_sidebar( 'home-sidebar-two-widget-area' );
} else {
/* Display notice to logged in users if there is no active widget in the sidebar */
if ( is_user_logged_in() && current_user_can( 'edit_theme_options' ) ){
if ( is_front_page() && $hipoul_settings['alt_home_sidebar'] ){
$sidebar_name = __( 'Front Page Sidebar Two Widget Area', 'graphene' );
} else {
$sidebar_name = __( 'Sidebar Two Widget Area', 'graphene' );
}
}
}
?>
<?php wp_meta(); ?>
<?php do_action( 'graphene_after_sidebar2' ); ?>
</div><!-- #sidebar2 -->