[wp-trac] [WordPress Trac] #12702: Enable sticky post checkbox for custom post type Publish metabox
WordPress Trac
wp-trac at lists.automattic.com
Mon Nov 29 06:37:00 UTC 2010
#12702: Enable sticky post checkbox for custom post type Publish metabox
-----------------------------+----------------------------------------------
Reporter: phlux0r | Owner:
Type: feature request | Status: new
Priority: normal | Milestone: 3.1
Component: Post Types | Version:
Severity: normal | Keywords: dev-feedback revert
-----------------------------+----------------------------------------------
Changes (by nacin):
* keywords: needs-patch => dev-feedback revert
Comment:
After some deliberation and an epiphany of sorts, I'm strongly considering
a complete revert of this.
Currently, sticky posts are only integrated into the loop if is_home and
not is_paged.
Sticky posts of a custom post type would thus only be included if the loop
also includes that post type in the query. (Looks like that logic is
there.)
However, this opens up an issue where we're blurring the line between CPTs
and posts, such that CPTs should be non-post content. If you want stuff to
appear in the main loop everywhere, then chances are you shouldn't be
using a CPT.
It also further opens up an issue where the post type and the loop must
cooperate and be in sync. If the loop doesn't include that post type, then
a post type supporting sticky-posts is just a useless UI element.
The other option is that a stickied CPT should then appear at the top of
is_post_type_archive rather than is_home. (Indeed, is_home is roughly
synonymous to is_post_type_archive, but for posts.) But then that requires
the support of has_archive.
I should note that stick_post() and unstick_post() make no checks on the
post type. So I'm thinking I leave [16004] in, and revert [15742] to be
considered again in the future.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/12702#comment:28>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list