Make WordPress Core

Changeset 20559


Ignore:
Timestamp:
04/21/2012 09:03:23 PM (13 years ago)
Author:
nacin
Message:

Adjust [20557] and check only parent(), as it is more semantic. We don't care if the theme considers itself to be a child theme, we care if it has a valid parent. see #20103.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/theme-editor.php

    r20558 r20559  
    162162<?php
    163163if ( $allowed_files ) :
    164     if ( $has_templates || $theme->is_child_theme() ) :
     164    if ( $has_templates || $theme->parent() ) :
    165165?>
    166166    <h3><?php _e('Templates'); ?></h3>
    167     <?php if ( $theme->is_child_theme() && $theme->parent() ) : ?>
     167    <?php if ( $theme->parent() ) : ?>
    168168    <p class="howto"><?php printf( __( 'This child theme inherits templates from a parent theme, %s.' ), '<a href="' . self_admin_url('theme-editor.php?theme=' . urlencode( $theme->get_template() ) ) . '">' . $theme->parent()->display('Name') . '</a>' ); ?></p>
    169169    <?php endif; ?>
Note: See TracChangeset for help on using the changeset viewer.