Changeset 21975 for trunk/wp-content/themes/twentytwelve/functions.php
- Timestamp:
- 09/24/2012 04:57:42 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-content/themes/twentytwelve/functions.php
r21929 r21975 216 216 } 217 217 add_action( 'widgets_init', 'twentytwelve_widgets_init' ); 218 219 /**220 * Counts the number of footer sidebars to enable dynamic classes for the footer.221 *222 * @since Twenty Twelve 1.0223 */224 function twentytwelve_frontpage_sidebar_class() {225 $classes = array( 'widget-area' );226 227 if ( is_active_sidebar( 'sidebar-2' ) && is_active_sidebar( 'sidebar-3' ) )228 $classes[] = 'two';229 230 echo 'class="' . implode( ' ', $classes ) . '"';231 }232 218 233 219 if ( ! function_exists( 'twentytwelve_content_nav' ) ) : … … 365 351 * 1. Using a full-width layout, when no active widgets in the sidebar 366 352 * or full-width template. 367 * 2. A thumbnail in the Front Page template. 353 * 2. Front Page template: thumbnail in use and number of sidebars for 354 * widget areas. 368 355 * 3. White or empty background color to change the layout and spacing. 356 * 4. Custom fonts enabled. 357 * 5. Single or multiple authors. 369 358 * 370 359 * @since Twenty Twelve 1.0 … … 383 372 if ( has_post_thumbnail() ) 384 373 $classes[] = 'has-post-thumbnail'; 374 if ( is_active_sidebar( 'sidebar-2' ) && is_active_sidebar( 'sidebar-3' ) ) 375 $classes[] = 'two-sidebars'; 385 376 } 386 377
Note: See TracChangeset
for help on using the changeset viewer.