The Twenty Twelve for WordPress.
props drewstrojny, lancewillett.
also props corvannoorloos, jeffsebring, kobenland, iandstewart, mfields,
mtdesign, op12no2, philiparthurmoore, sixhours, mamaduka.
see #19978.
git-svn-id: http://core.svn.wordpress.org/trunk@21261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-07-12 00:20:46 -04:00
|
|
|
<?php
|
|
|
|
/**
|
2012-08-25 12:53:32 -04:00
|
|
|
* The sidebar containing the homepage widget areas.
|
The Twenty Twelve for WordPress.
props drewstrojny, lancewillett.
also props corvannoorloos, jeffsebring, kobenland, iandstewart, mfields,
mtdesign, op12no2, philiparthurmoore, sixhours, mamaduka.
see #19978.
git-svn-id: http://core.svn.wordpress.org/trunk@21261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-07-12 00:20:46 -04:00
|
|
|
*
|
2012-08-20 14:45:00 -04:00
|
|
|
* If no active widgets in either sidebar, they will be hidden completely.
|
The Twenty Twelve for WordPress.
props drewstrojny, lancewillett.
also props corvannoorloos, jeffsebring, kobenland, iandstewart, mfields,
mtdesign, op12no2, philiparthurmoore, sixhours, mamaduka.
see #19978.
git-svn-id: http://core.svn.wordpress.org/trunk@21261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-07-12 00:20:46 -04:00
|
|
|
*
|
|
|
|
* @package WordPress
|
|
|
|
* @subpackage Twenty_Twelve
|
|
|
|
* @since Twenty Twelve 1.0
|
|
|
|
*/
|
2012-08-20 14:45:00 -04:00
|
|
|
|
|
|
|
/*
|
2012-08-25 12:53:32 -04:00
|
|
|
* The homepage widget area is triggered if any of the areas
|
|
|
|
* have widgets. So let's check that first.
|
|
|
|
*
|
|
|
|
* If none of the sidebars have widgets, then let's bail early.
|
|
|
|
*/
|
2012-08-28 13:16:18 -04:00
|
|
|
if ( ! is_active_sidebar( 'sidebar-2' ) && ! is_active_sidebar( 'sidebar-3' ) )
|
2012-08-20 14:45:00 -04:00
|
|
|
return;
|
|
|
|
|
|
|
|
// If we get this far, we have widgets. Let do this.
|
The Twenty Twelve for WordPress.
props drewstrojny, lancewillett.
also props corvannoorloos, jeffsebring, kobenland, iandstewart, mfields,
mtdesign, op12no2, philiparthurmoore, sixhours, mamaduka.
see #19978.
git-svn-id: http://core.svn.wordpress.org/trunk@21261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-07-12 00:20:46 -04:00
|
|
|
?>
|
2012-08-20 14:45:00 -04:00
|
|
|
<div id="secondary" <?php twentytwelve_homepage_sidebar_class(); ?> role="complementary">
|
2012-08-28 13:16:18 -04:00
|
|
|
<?php if ( is_active_sidebar( 'sidebar-2' ) ) : ?>
|
2012-08-20 14:45:00 -04:00
|
|
|
<div class="first home-widgets">
|
2012-08-28 13:16:18 -04:00
|
|
|
<?php dynamic_sidebar( 'sidebar-2' ); ?>
|
2012-08-25 13:16:56 -04:00
|
|
|
</div><!-- .first -->
|
2012-08-20 14:45:00 -04:00
|
|
|
<?php endif; ?>
|
The Twenty Twelve for WordPress.
props drewstrojny, lancewillett.
also props corvannoorloos, jeffsebring, kobenland, iandstewart, mfields,
mtdesign, op12no2, philiparthurmoore, sixhours, mamaduka.
see #19978.
git-svn-id: http://core.svn.wordpress.org/trunk@21261 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-07-12 00:20:46 -04:00
|
|
|
|
2012-08-28 13:16:18 -04:00
|
|
|
<?php if ( is_active_sidebar( 'sidebar-3' ) ) : ?>
|
2012-08-20 14:45:00 -04:00
|
|
|
<div class="second home-widgets">
|
2012-08-28 13:16:18 -04:00
|
|
|
<?php dynamic_sidebar( 'sidebar-3' ); ?>
|
2012-08-25 13:16:56 -04:00
|
|
|
</div><!-- .second -->
|
2012-08-20 14:45:00 -04:00
|
|
|
<?php endif; ?>
|
2012-08-25 13:16:56 -04:00
|
|
|
</div><!-- #secondary -->
|