Make WordPress Core

Ticket #29127: 29127.twentythirteen.patch

File 29127.twentythirteen.patch, 3.4 KB (added by lancewillett, 11 years ago)

Twenty Thirteen cleanup

  • wp-content/themes/twentythirteen/functions.php

     
    146146                        'family' => urlencode( implode( '|', $font_families ) ),
    147147                        'subset' => urlencode( 'latin,latin-ext' ),
    148148                );
    149                 $fonts_url = add_query_arg( $query_args, "//fonts.googleapis.com/css" );
     149                $fonts_url = add_query_arg( $query_args, '//fonts.googleapis.com/css' );
    150150        }
    151151
    152152        return $fonts_url;
     
    319319 */
    320320function twentythirteen_entry_meta() {
    321321        if ( is_sticky() && is_home() && ! is_paged() )
    322                 echo '<span class="featured-post">' . __( 'Sticky', 'twentythirteen' ) . '</span>';
     322                echo '<span class="featured-post">' . esc_html__( 'Sticky', 'twentythirteen' ) . '</span>';
    323323
    324324        if ( ! has_post_format( 'link' ) && 'post' == get_post_type() )
    325325                twentythirteen_entry_date();
     
    413413                'post_type'      => 'attachment',
    414414                'post_mime_type' => 'image',
    415415                'order'          => 'ASC',
    416                 'orderby'        => 'menu_order ID'
     416                'orderby'        => 'menu_order ID',
    417417        ) );
    418418
    419419        // If there is more than 1 attachment in a gallery...
  • wp-content/themes/twentythirteen/inc/custom-header.php

     
    217217 */
    218218function twentythirteen_admin_header_image() {
    219219        ?>
    220         <div id="headimg" style="background: url(<?php header_image(); ?>) no-repeat scroll top; background-size: 1600px auto;">
    221                 <?php $style = ' style="color:#' . get_header_textcolor() . ';"'; ?>
     220        <div id="headimg" style="background: url(<?php echo esc_url( get_header_image() ); ?>) no-repeat scroll top; background-size: 1600px auto;">
     221                <?php
     222                $style = 'color: #' . get_header_textcolor() . ';';
     223                if ( ! display_header_text() ) {
     224                        $style = 'display: none;';
     225                }
     226                ?>
    222227                <div class="home-link">
    223                         <h1 class="displaying-header-text"><a id="name"<?php echo $style; ?> onclick="return false;" href="#"><?php bloginfo( 'name' ); ?></a></h1>
    224                         <h2 id="desc" class="displaying-header-text"<?php echo $style; ?>><?php bloginfo( 'description' ); ?></h2>
     228                        <h1 class="displaying-header-text"><a id="name" style="<?php echo esc_attr( $style ); ?>" onclick="return false;" href="#"><?php bloginfo( 'name' ); ?></a></h1>
     229                        <h2 id="desc" class="displaying-header-text" style="<?php echo esc_attr( $style ); ?>"><?php bloginfo( 'description' ); ?></h2>
    225230                </div>
    226231        </div>
    227232<?php }
  • wp-content/themes/twentythirteen/taxonomy-post_format.php

     
    2020
    2121                <?php if ( have_posts() ) : ?>
    2222                        <header class="archive-header">
    23                                 <h1 class="archive-title"><?php printf( __( '%s Archives', 'twentythirteen' ), '<span>' . get_post_format_string( get_post_format() ) . '</span>' ); ?></h1>
     23                                <h1 class="archive-title"><?php printf( __( '%s Archives', 'twentythirteen' ), '<span>' . esc_html( get_post_format_string( get_post_format() ) ) . '</span>' ); ?></h1>
    2424                        </header><!-- .archive-header -->
    2525
    2626                        <?php /* The loop */ ?>