.
add_theme_support( 'automatic-feed-links' );
// This theme uses wp_nav_menu() in one location.
register_nav_menu( 'primary', __( 'Primary Menu', 'twentytwelve' ) );
// Add support for custom backgrounds
add_custom_background();
}
endif;
/**
* Get our wp_nav_menu() fallback, wp_page_menu(), to show a home link.
*
* @since Twenty Twelve 1.0
*/
function twentytwelve_page_menu_args( $args ) {
$args['show_home'] = true;
return $args;
}
add_filter( 'wp_page_menu_args', 'twentytwelve_page_menu_args' );
/**
* Register our single widget area.
*
* @since Twenty Twelve 1.0
*/
function twentytwelve_widgets_init() {
register_sidebar( array(
'name' => __( 'Main Sidebar', 'twentytwelve' ),
'id' => 'sidebar-1',
'before_widget' => '",
'before_title' => '
',
) );
}
add_action( 'widgets_init', 'twentytwelve_widgets_init' );
if ( ! function_exists( 'twentytwelve_content_nav' ) ) :
/**
* Display navigation to next/previous pages when applicable
*
* @since Twenty Twelve 1.0
*/
function twentytwelve_content_nav( $nav_id ) {
global $wp_query;
if ( $wp_query->max_num_pages > 1 ) : ?>
comment_type ) :
case 'pingback' :
case 'trackback' :
?>
', '' ); ?>
id="li-comment-">
Posted on by %7$s', 'twentytwelve' ),
esc_url( get_permalink() ),
esc_attr( get_the_time() ),
esc_attr( get_the_date( 'c' ) ),
esc_html( get_the_date() ),
esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
esc_attr( sprintf( __( 'View all posts by %s', 'twentytwelve' ), get_the_author() ) ),
get_the_author()
);
}
endif;