[wp-testers] Archive of pages uses home.php template

Otto otto at ottodestruct.com
Sun Apr 3 15:53:08 UTC 2011


That sounds correct to me. The post_type isn't a template trigger, it
doesn't affect which template gets used anywhere, really. So it's
seeing a more-or-less home type query, which would use home.php.

The page trigger is page= and that would make it use a page template
or page.php, because that is specifying a single page. There's no
other appropriate template for multiple page entries except for
home/index, really.

-Otto



On Sun, Apr 3, 2011 at 7:41 AM,  <michael at mfields.org> wrote:
> Hi,
>
> Think I just came across a bug.
>
> Running the following query from the location bar will produce a list of
> all pages on a site: ?post_type=page. In the event that the theme has a
> home.php template, this template will be used to display the archive. I
> believe that home.php is intended to be used only when the "Blog" is being
> queried (posts with a post_type of "post" with no modifiers). All custom
> post types fall back to index.php if there is no dedicated template
> however, pages are somehow triggering home.php.
>
> I have also tested with an archive-page.php template, but home.php always
> seems to be used when multiple pages are queried by post_type.
>
> Please let me know your thoughts!
>
> -Mike
>
> _______________________________________________
> wp-testers mailing list
> wp-testers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-testers
>


More information about the wp-testers mailing list