Make WordPress Core

Changeset 26599


Ignore:
Timestamp:
12/04/2013 03:28:31 AM (12 years ago)
Author:
lancewillett
Message:

Twenty Fourteen: remove wp_is_mobile() call from post thumbnail size logic as it's not intended for front-end use. Props kwight, fixes #26221.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentyfourteen/inc/template-tags.php

    r26572 r26599  
    166166
    167167/**
    168  * Display an optional post thumbnail on a single view.
    169  *
    170  * Adds an anchor element to the post thumbnail, when on
    171  * index views, and a div element when on a single view.
     168 * Display an optional post thumbnail.
     169 *
     170 * Wraps the post thumbnail in an anchor element on index
     171 * views, or a div element when on single views.
    172172 *
    173173 * @since Twenty Fourteen 1.0
     
    185185    <div class="post-thumbnail">
    186186    <?php
    187         if ( ( ! is_active_sidebar( 'sidebar-2' ) || is_page_template( 'page-templates/full-width.php' ) ) && ! wp_is_mobile() ) {
     187        if ( ( ! is_active_sidebar( 'sidebar-2' ) || is_page_template( 'page-templates/full-width.php' ) ) ) {
    188188            the_post_thumbnail( 'twentyfourteen-full-width' );
    189189        } else {
     
    197197    <a class="post-thumbnail" href="<?php the_permalink(); ?>" rel="<?php the_ID(); ?>">
    198198    <?php
    199         if ( ( ! is_active_sidebar( 'sidebar-2' ) || is_page_template( 'page-templates/full-width.php' ) ) && ! wp_is_mobile() ) {
     199        if ( ( ! is_active_sidebar( 'sidebar-2' ) || is_page_template( 'page-templates/full-width.php' ) ) ) {
    200200            the_post_thumbnail( 'twentyfourteen-full-width' );
    201201        } else {
Note: See TracChangeset for help on using the changeset viewer.