[wp-trac] [WordPress Trac] #40820: Child theme should appear as broken if parent is itself
WordPress Trac
noreply at wordpress.org
Fri May 19 13:58:51 UTC 2017
#40820: Child theme should appear as broken if parent is itself
--------------------------+-----------------------------
Reporter: davilera | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Themes | Version: 4.7.5
Severity: normal | Keywords:
Focuses: template |
--------------------------+-----------------------------
Child themes are defined as such if they include the `Template` header in
`style.css`. In general, if the parent template can't be found, WordPress
reports the theme as ''Broken'' and tells the user to install the missing
parent theme.
However, if the `Template` header is the theme itself, no errors are
reported (WordPress can find the "parent" theme, because it's itself). The
resulting behavior is weird and unexpected:
* If there are other themes available, WordPress uses one as the parent
theme (I don't know which criteria is used for selecting one or the
other).
* If there aren't, the front-end is completely blank (but this might
depend on the amount of code included in the child theme).
Such an (invalid) child theme should be reported as ''Broken''. For
instance, the following message could be shown: ''The theme defines itself
as its parent theme. Please fix the "Template" header.''
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40820>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list