twentyeleven_body_classes

Add two classes to the array of body classes.

Description

twentyeleven_body_classes( $classes ); 

The first is if the site has only had one author with published posts. The second is if a singular post being displayed

Parameters (1)

0. $classes
The classes.

Usage

  1. if ( !function_exists( 'twentyeleven_body_classes' ) ) { 
  2. require_once '/functions.php'; 
  3.  
  4. // The classes. 
  5. $classes = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = twentyeleven_body_classes($classes); 
  9.  

Defined (1)

The function is defined in the following location(s).

/functions.php  
  1. function twentyeleven_body_classes( $classes ) { 
  2.  
  3. if ( ! is_multi_author() ) { 
  4. $classes[] = 'single-author'; 
  5.  
  6. if ( is_singular() && ! is_home() && ! is_page_template( 'showcase.php' ) && ! is_page_template( 'sidebar-page.php' ) ) 
  7. $classes[] = 'singular'; 
  8.  
  9. return $classes;