[wp-trac] [WordPress Trac] #33017: Images displayed with page.php instead of index.php

WordPress Trac noreply at wordpress.org
Mon Oct 31 00:17:08 UTC 2016


#33017: Images displayed with page.php instead of index.php
-------------------------------------------------+-------------------------
 Reporter:  creon                                |       Owner:
     Type:  defect (bug)                         |      Status:  reopened
 Priority:  normal                               |   Milestone:  Awaiting
Component:  Themes                               |  Review
 Severity:  normal                               |     Version:
 Keywords:  needs-patch 2nd-opinion needs-unit-  |  Resolution:
  tests                                          |     Focuses:  template
-------------------------------------------------+-------------------------
Changes (by johnbillion):

 * keywords:   => needs-patch 2nd-opinion needs-unit-tests
 * milestone:   => Awaiting Review


Comment:

 Confirmed. When viewing an attachment uploaded to a Page, `is_page()` is
 true, causing the template hierarchy to include templates for `page.php`
 etc, too. The same does not occur when viewing an attachment uploaded to a
 Post.

 Changing this might cause a break in expected behaviour. Needs good test
 coverage and a patch.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/33017#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list