Ticket #25758: 25758.2.diff
File 25758.2.diff, 1.6 KB (added by , 11 years ago) |
---|
-
src/wp-content/themes/twentyfourteen/functions.php
69 69 70 70 // Add several sizes for Post Thumbnails. 71 71 add_image_size( 'post-thumbnail-slider', 1038, 576, true ); 72 add_image_size( 'post-thumbnail-full-width', 1038, 0 ); 72 73 add_image_size( 'post-thumbnail-grid', 672, 372, true ); 73 74 add_image_size( 'post-thumbnail', 672, 0 ); 74 75 -
src/wp-content/themes/twentyfourteen/inc/template-tags.php
172 172 ?> 173 173 174 174 <div class="post-thumbnail"> 175 <?php the_post_thumbnail( 'post-thumbnail' ); ?> 175 <?php 176 if ( is_active_sidebar( 'sidebar-2' ) || wp_is_mobile() ) 177 the_post_thumbnail( 'post-thumbnail' ); 178 else 179 the_post_thumbnail( 'post-thumbnail-full-width' ); 180 ?> 176 181 </div> 177 182 178 183 <?php else : ?> 179 184 180 185 <a class="post-thumbnail" href="<?php the_permalink(); ?>" rel="<?php the_ID(); ?>"> 181 <?php if ( has_post_thumbnail() ) :186 <?php if ( has_post_thumbnail() && ( is_active_sidebar( 'sidebar-2' ) || wp_is_mobile() ) ) : 182 187 the_post_thumbnail( 'post-thumbnail' ); 188 elseif ( has_post_thumbnail() ) : 189 the_post_thumbnail( 'post-thumbnail-full-width' ); 183 190 else : ?> 184 191 <p class="screen-reader-text"><?php _e( 'No featured image.', 'twentyfourteen' ); ?></p> 185 192 <?php endif; ?>