Make WordPress Core

Ticket #25256: twentyeleven.2.diff

File twentyeleven.2.diff, 12.9 KB (added by ericlewis, 12 years ago)
  • src/wp-content/themes/twentyeleven/author.php

     
    1515                        <?php if ( have_posts() ) : ?>
    1616
    1717                                <?php
    18                                         /**
    19                                          * Queue the first post, that way we know what author
     18                                        /* Queue the first post, that way we know what author
    2019                                         * we're dealing with (if that is the case).
    2120                                         *
    2221                                         * We reset this later so we can run the loop properly
     
    3029                                </header>
    3130
    3231                                <?php
    33                                         /**
    34                                          * Since we called the_post() above, we need to
     32                                        /* Since we called the_post() above, we need to
    3533                                         * rewind the loop back to the beginning that way
    3634                                         * we can run the loop properly, in full.
    3735                                         */
     
    6765                                <?php while ( have_posts() ) : the_post(); ?>
    6866
    6967                                        <?php
    70                                                 /**
    71                                                  * Include the Post-Format-specific template for the content.
     68                                                /* Include the Post-Format-specific template for the content.
    7269                                                 * If you want to overload this in a child theme then include a file
    7370                                                 * called content-___.php (where ___ is the Post Format name) and that will be used instead.
    7471                                                 */
  • src/wp-content/themes/twentyeleven/category.php

     
    4040                                <?php while ( have_posts() ) : the_post(); ?>
    4141
    4242                                        <?php
    43                                                 /**
    44                                                  * Include the Post-Format-specific template for the content.
     43                                                /* Include the Post-Format-specific template for the content.
    4544                                                 * If you want to overload this in a child theme then include a file
    4645                                                 * called content-___.php (where ___ is the Post Format name) and that will be used instead.
    4746                                                 */
  • src/wp-content/themes/twentyeleven/comments.php

     
    1717                <p class="nopassword"><?php _e( 'This post is password protected. Enter the password to view any comments.', 'twentyeleven' ); ?></p>
    1818        </div><!-- #comments -->
    1919        <?php
    20                         /**
    21                          * Stop the rest of comments.php from being processed,
     20                        /* Stop the rest of comments.php from being processed,
    2221                         * but don't kill the script entirely -- we still have
    2322                         * to fully load the template.
    2423                         */
     
    4645
    4746                <ol class="commentlist">
    4847                        <?php
    49                                 /**
    50                                  * Loop through and list the comments. Tell wp_list_comments()
     48                                /* Loop through and list the comments. Tell wp_list_comments()
    5149                                 * to use twentyeleven_comment() to format the comments.
    5250                                 * If you want to overload this in a child theme then you can
    5351                                 * define twentyeleven_comment() and that will be used instead.
     
    6664                <?php endif; // check for comment navigation ?>
    6765
    6866                <?php
    69                 /**
    70                  * If there are no comments and comments are closed, let's leave a little note, shall we?
     67                /* If there are no comments and comments are closed, let's leave a little note, shall we?
    7168                 * But we only want the note on posts and pages that had comments in the first place.
    7269                 */
    7370                if ( ! comments_open() && get_comments_number() ) : ?>
  • src/wp-content/themes/twentyeleven/footer.php

     
    1515        <footer id="colophon" role="contentinfo">
    1616
    1717                        <?php
    18                                 /**
    19                                  * A sidebar in the footer? Yep. You can can customize
     18                                /* A sidebar in the footer? Yep. You can can customize
    2019                                 * your footer with three columns of widgets.
    2120                                 */
    2221                                if ( ! is_404() )
  • src/wp-content/themes/twentyeleven/functions.php

     
    3838 * @since Twenty Eleven 1.0
    3939 */
    4040
    41 /**
    42  * Set the content width based on the theme's design and stylesheet.
    43  */
     41// Set the content width based on the theme's design and stylesheet.
    4442if ( ! isset( $content_width ) )
    4543        $content_width = 584;
    4644
    47 /**
    48  * Tell WordPress to run twentyeleven_setup() when the 'after_setup_theme' hook is run.
    49  */
     45// Tell WordPress to run twentyeleven_setup() when the 'after_setup_theme' hook is run.
    5046add_action( 'after_setup_theme', 'twentyeleven_setup' );
    5147
    5248if ( ! function_exists( 'twentyeleven_setup' ) ):
     
    7268 */
    7369function twentyeleven_setup() {
    7470
    75         /**
    76          * Make Twenty Eleven available for translation.
     71        /* Make Twenty Eleven available for translation.
    7772         * Translations can be added to the /languages/ directory.
    7873         * If you're building a theme based on Twenty Eleven, use
    7974         * a find and replace to change 'twentyeleven' to the name
     
    107102
    108103        // Add support for custom backgrounds.
    109104        add_theme_support( 'custom-background', array(
    110                 /**
    111                  * Let WordPress know what our default background color is.
     105                /* Let WordPress know what our default background color is.
    112106                 * This is dependent on our current color scheme.
    113107                 */
    114108                'default-color' => $default_background_color,
     
    162156                add_custom_background();
    163157        }
    164158
    165         /**
    166          * We'll be using post thumbnails for custom header images on posts and pages.
     159        /* We'll be using post thumbnails for custom header images on posts and pages.
    167160         * We want them to be the size of the header image that we just defined.
    168161         * Larger images will be auto-cropped to fit, smaller ones will be ignored. See header.php.
    169162         */
    170163        set_post_thumbnail_size( $custom_header_support['width'], $custom_header_support['height'], true );
    171164
    172         /**
    173          * Add Twenty Eleven's custom image sizes.
     165        /* Add Twenty Eleven's custom image sizes.
    174166         * Used for large feature (header) images.
    175167         */
    176168        add_image_size( 'large-feature', $custom_header_support['width'], $custom_header_support['height'], true );
  • src/wp-content/themes/twentyeleven/header.php

     
    2525<meta charset="<?php bloginfo( 'charset' ); ?>" />
    2626<meta name="viewport" content="width=device-width" />
    2727<title><?php
    28         /**
    29          * Print the <title> tag based on what is being viewed.
    30          */
     28        // Print the <title> tag based on what is being viewed.
    3129        global $page, $paged;
    3230
    3331        wp_title( '|', true, 'right' );
     
    5250<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
    5351<![endif]-->
    5452<?php
    55         /**
    56          * We add some JavaScript to pages with the comment form
     53        /* We add some JavaScript to pages with the comment form
    5754         * to support sites with threaded comments (when in use).
    5855         */
    5956        if ( is_singular() && get_option( 'thread_comments' ) )
    6057                wp_enqueue_script( 'comment-reply' );
    6158
    62         /**
    63          * Always have wp_head() just before the closing </head>
     59        /* Always have wp_head() just before the closing </head>
    6460         * tag of your theme, or you will break many plugins, which
    6561         * generally use this hook to add elements to <head> such
    6662         * as styles, scripts, and meta tags.
     
    8379                                if ( $header_image ) :
    8480                                        // Compatibility with versions of WordPress prior to 3.4.
    8581                                        if ( function_exists( 'get_custom_header' ) ) {
    86                                                 /**
    87                                                  * We need to figure out what the minimum width should be for our featured image.
     82                                                /* We need to figure out what the minimum width should be for our featured image.
    8883                                                 * This result would be the suggested width if the theme were to implement flexible widths.
    8984                                                 */
    9085                                                $header_image_width = get_theme_support( 'custom-header', 'width' );
     
    9489                                        ?>
    9590                        <a href="<?php echo esc_url( home_url( '/' ) ); ?>">
    9691                                <?php
    97                                         /**
    98                                          * The header image.
     92                                        /* The header image.
    9993                                         * Check if this is a post or page, if it has a thumbnail, and if it's a big one
    10094                                         */
    10195                                        if ( is_singular() && has_post_thumbnail( $post->ID ) &&
  • src/wp-content/themes/twentyeleven/image.php

     
    4848                                                        <div class="entry-attachment">
    4949                                                                <div class="attachment">
    5050<?php
    51         /**
    52          * Grab the IDs of all the image attachments in a gallery so we can get the URL of the next adjacent image in a gallery,
     51        /* Grab the IDs of all the image attachments in a gallery so we can get the URL of the next adjacent image in a gallery,
    5352         * or the first image (if we're looking at the last image in a gallery), or, in a gallery of one, just the link to that image file
    5453         */
    5554        $attachments = array_values( get_children( array( 'post_parent' => $post->post_parent, 'post_status' => 'inherit', 'post_type' => 'attachment', 'post_mime_type' => 'image', 'order' => 'ASC', 'orderby' => 'menu_order ID' ) ) );
  • src/wp-content/themes/twentyeleven/search.php

     
    2424                                <?php while ( have_posts() ) : the_post(); ?>
    2525
    2626                                        <?php
    27                                                 /**
    28                                                  * Include the Post-Format-specific template for the content.
     27                                                /* Include the Post-Format-specific template for the content.
    2928                                                 * If you want to overload this in a child theme then include a file
    3029                                                 * called content-___.php (where ___ is the Post Format name) and that
    3130                                                 * will be used instead.
  • src/wp-content/themes/twentyeleven/showcase.php

     
    2626                                <?php while ( have_posts() ) : the_post(); ?>
    2727
    2828                                <?php
    29                                         /**
    30                                          * We are using a heading by rendering the_content
     29                                        /* We are using a heading by rendering the_content
    3130                                         * If we have content for this page, let's display it.
    3231                                         */
    3332                                        if ( '' != get_the_content() )
     
    3736                                <?php endwhile; ?>
    3837
    3938                                <?php
    40                                         /**
    41                                          * Begin the featured posts section.
     39                                        /* Begin the featured posts section.
    4240                                         *
    4341                                         * See if we have any sticky posts and use them to create our featured posts.
    4442                                         * We limit the featured posts at ten.
     
    6159                                        // Proceed only if published posts exist
    6260                                        if ( $featured->have_posts() ) :
    6361
    64                                         /**
    65                                          * We will need to count featured posts starting from zero
     62                                        /* We will need to count featured posts starting from zero
    6663                                         * to create the slider navigation.
    6764                                         */
    6865                                        $counter_slider = 0;
     
    8481                                        // Increase the counter.
    8582                                        $counter_slider++;
    8683
    87                                         /**
    88                                          * We're going to add a class to our featured post for featured images
     84                                        /* We're going to add a class to our featured post for featured images
    8985                                         * by default it'll have the feature-text class.
    9086                                         */
    9187                                        $feature_class = 'feature-text';
     
    108104                                        <section class="featured-post <?php echo $feature_class; ?>" id="featured-post-<?php echo $counter_slider; ?>">
    109105
    110106                                                <?php
    111                                                         /**
    112                                                          * If the thumbnail is as big as the header image
     107                                                        /* If the thumbnail is as big as the header image
    113108                                                         * make it a large featured post, otherwise render it small
    114109                                                         */
    115110                                                        if ( has_post_thumbnail() ) {
  • src/wp-content/themes/twentyeleven/sidebar-footer.php

     
    99?>
    1010
    1111<?php
    12         /**
    13          * The footer widget area is triggered if any of the areas
     12        /* The footer widget area is triggered if any of the areas
    1413         * have widgets. So let's check that first.
    1514         *
    1615         * If none of the sidebars have widgets, then let's bail early.
  • src/wp-content/themes/twentyeleven/tag.php

     
    4040                                <?php while ( have_posts() ) : the_post(); ?>
    4141
    4242                                        <?php
    43                                                 /**
    44                                                  * Include the Post-Format-specific template for the content.
     43                                                /* Include the Post-Format-specific template for the content.
    4544                                                 * If you want to overload this in a child theme then include a file
    4645                                                 * called content-___.php (where ___ is the Post Format name) and that
    4746                                                 * will be used instead.