13. Comments
/**
* Tell WordPress to run twentyeleven_setup() when the
* 'after_setup_theme' hook is run.
*/
add_action( 'after_setup_theme', 'twentyeleven_setup' );
/**
* Sets the post excerpt length to 40 words.
*
* To override this length in a child theme,
* remove the filter and add your own
* function tied to the excerpt_length filter hook.
*/
function twentyeleven_excerpt_length( $length ) {
Sunday, March 25, 12
14. Comments
// Turn on random header image rotation by default.
add_theme_support( 'custom-header', array( 'random-
default' => true ) );
// Has the text been hidden?
if ( 'blank' == get_header_textcolor() ) :
...
...
// If the user has set a custom color for the text use
else :
....
....
endif;
Sunday, March 25, 12
15. Comments
/**
* The Template for displaying all single posts.
*
* @package WordPress
* @subpackage Twenty_Eleven
* @since Twenty Eleven 1.0
*/
<div id="primary">
! <div id="content" role="main">
.....
.....
</div><!-- #content -->
</div><!-- #primary -->
Sunday, March 25, 12