Commit Graph

323 Commits

Author SHA1 Message Date
scribu cc34c8aef4 Inline docs for WP_Tax_Query. See #15752
git-svn-id: http://svn.automattic.com/wordpress/trunk@16854 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-10 08:20:46 +00:00
scribu 6f9d098c9b Correct relation var and PHP4 constructor. See #15752
git-svn-id: http://svn.automattic.com/wordpress/trunk@16850 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 19:36:33 +00:00
scribu e5690e7ebe Introduce WP_Tax_Query. Fix canonical redirects in the process. See #15752
git-svn-id: http://svn.automattic.com/wordpress/trunk@16849 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 19:29:21 +00:00
scribu 5fd4580daa False advertising is bad. See #15752
git-svn-id: http://svn.automattic.com/wordpress/trunk@16845 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 17:19:23 +00:00
scribu e11b831338 Set tax query defaults earlier, for notice prevention and convenience. See #15752
git-svn-id: http://svn.automattic.com/wordpress/trunk@16843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 17:05:40 +00:00
nacin 5aafa64e34 Use correct query var. see #15378.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16837 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 14:23:54 +00:00
scribu 8ba8d20f16 Make get_term_by() use sanitize_title_for_query() too. See #9591
git-svn-id: http://svn.automattic.com/wordpress/trunk@16832 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 10:05:19 +00:00
ryan 83d1c0bf29 Use santize_key() in more places. Props WraithKenny. fixes #14910
git-svn-id: http://svn.automattic.com/wordpress/trunk@16822 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-08 21:32:19 +00:00
nacin 47cfe8dd05 Post format indexes. First pass. see #15378.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16705 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-03 10:13:17 +00:00
westi 57fca2acf3 Clean the cache when deleting a term. Fixes #15651
git-svn-id: http://svn.automattic.com/wordpress/trunk@16691 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-02 17:10:02 +00:00
scribu 0c8a8c3655 Get rid of misplaced 'taxonomy_template' filter. Fixes #14740
git-svn-id: http://svn.automattic.com/wordpress/trunk@16665 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-01 20:16:24 +00:00
scribu 719b8d8f4a Introduce 'relation' operator between tax queries. Props Otto42 for initial patch. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16555 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-23 20:22:27 +00:00
nacin 69b3167678 Revert [15688], [15689], [15691]. Try again in 3.2. see #14966.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16535 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-22 17:17:26 +00:00
scribu 24f00c889f Update get_tax_sql() docblock. See #14579
git-svn-id: http://svn.automattic.com/wordpress/trunk@16523 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-21 14:09:01 +00:00
scribu 36658f37ca Fix logic for when excluding a non-existant term. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16512 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-20 21:28:50 +00:00
ryan 44733f9635 If the queried term does not exist make sure no posts are returned in the query rather than falling through to querying all posts. Fixes 404s when querying cats that do not exist. see #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16511 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-20 21:10:20 +00:00
markjaquith e2879c73fa Exclude term exclusions even if they are also inclusions. props foofy, scribu. see #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16467 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-18 19:04:47 +00:00
scribu d23ca4da48 Clarify doc-block for wp_delete_object_term_relationships(). Props simonwheatley. Fixes #15472
git-svn-id: http://svn.automattic.com/wordpress/trunk@16466 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-18 18:46:41 +00:00
ryan 847499e531 Pinking shears
git-svn-id: http://svn.automattic.com/wordpress/trunk@16438 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-17 18:47:34 +00:00
scribu a0e5b38765 Fix ambiguous column error. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16423 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-17 12:33:32 +00:00
scribu f58b21e69d Optimize get_tax_sql(). See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16413 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-17 01:56:01 +00:00
scribu af6dbfde54 Revert taxonomy.php part of [16402]. Not fully backed yet. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16403 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-16 16:24:14 +00:00
scribu 690cd434d1 Don't pollute the 'tax_query' query var. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16402 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-16 16:22:09 +00:00
scribu 9e939da4f3 Fix get_tax_sql() docs. Props Viper007Bond. Fixes #15431
git-svn-id: http://svn.automattic.com/wordpress/trunk@16382 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-15 11:24:55 +00:00
scribu 2b58e241d0 Better error handling in get_meta_sql(). Props Viper007Bond. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16379 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-15 10:02:39 +00:00
scribu 03dd41a0d2 Improve hook readability via curly brackets. Props jjj for initial patch. Fixes #15422
git-svn-id: http://svn.automattic.com/wordpress/trunk@16365 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-14 15:50:02 +00:00
nacin fd4b0965f8 Only register post_format taxonomy to posts. see #15396, #14746.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16322 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-12 10:58:58 +00:00
scribu 3cbc8ef308 Make get_tax_sql() a standalone function. See #15032
git-svn-id: http://svn.automattic.com/wordpress/trunk@16267 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-09 23:30:35 +00:00
nacin 91d3b6bea9 Introduce menu_name label for taxonomies and post types. Defaults to name. fixes #14832.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16251 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-09 02:09:00 +00:00
scribu 568620021d Introduce get_terms_args filter. Fixes #15020
git-svn-id: http://svn.automattic.com/wordpress/trunk@16059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-28 19:09:18 +00:00
scribu bc5d96f856 Add terms_clauses filter. Props sc0ttkclark for initial patch. See #15020
git-svn-id: http://svn.automattic.com/wordpress/trunk@16056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-28 17:55:30 +00:00
scribu c613576e77 Introduce sanitize_title_for_query(). See #9591
git-svn-id: http://svn.automattic.com/wordpress/trunk@15929 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-23 12:55:55 +00:00
scribu 99f5c0f184 Remove debugging code in wp_check_term_hierarchy_for_loops(). See #14662
git-svn-id: http://svn.automattic.com/wordpress/trunk@15922 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-22 21:31:57 +00:00
nacin 14ccdbec33 Pruning shears.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15904 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-21 19:55:28 +00:00
nacin 5e1184aa57 Pinking shears.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-19 07:48:22 +00:00
nacin 76e493c281 Full @since's for 3.1.0.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15842 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-19 07:38:42 +00:00
dd32 81924ad20b Merge Category/Tag URL creation/rewriting into general Taxonomy system. Removes the legacy handling for these url's. See #12659
git-svn-id: http://svn.automattic.com/wordpress/trunk@15825 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-17 05:41:22 +00:00
dd32 baa0935d9a Move hierarchical_url to $args['rewrite']['hierarchical']
git-svn-id: http://svn.automattic.com/wordpress/trunk@15824 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-17 04:36:26 +00:00
ryan 3df9f849ce nav_menu and post_format taxonomies should not be public. fixes #15107
git-svn-id: http://svn.automattic.com/wordpress/trunk@15818 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-15 14:53:55 +00:00
ryan 0a01e66745 Prevent post and term hierarchy loops. Props mdawaffe. fixes #14662
git-svn-id: http://svn.automattic.com/wordpress/trunk@15806 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-14 15:09:04 +00:00
ryan 6ffa9e31d3 Don't hide empty terms when determing exclude trees. Props layotte. fixes #14446
git-svn-id: http://svn.automattic.com/wordpress/trunk@15797 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-13 20:12:20 +00:00
ryan 0982c3c0f9 Post formats, take one. see #14746
git-svn-id: http://svn.automattic.com/wordpress/trunk@15777 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-12 18:33:14 +00:00
nacin b7bacd1bf2 s/Wether/Whether/
git-svn-id: http://svn.automattic.com/wordpress/trunk@15756 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-08 02:35:06 +00:00
scribu 54304cc2d4 Prevent db error when dealing with unexistant parent term. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@15734 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-06 12:06:23 +00:00
scribu 38888b588d Make hierarchical URLs work for any hierarchical taxonomy. See #12659
git-svn-id: http://svn.automattic.com/wordpress/trunk@15732 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-06 11:04:03 +00:00
scribu a8367fa6f2 Generalize taxonomy queries:
* transform wp_tax_query() into WP_Object_Query::get_tax_sql()
	* create parse_tax_query() method in WP_Query
	* add doc-block for $tax_query and $meta_query
See #15032. See #12891.


git-svn-id: http://svn.automattic.com/wordpress/trunk@15731 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-06 10:40:30 +00:00
nacin 7119d7429e Restore wp_delete_category. props blepoxp, fixes #15008.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15712 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-04 16:28:01 +00:00
dd32 d9e1a542ee Introduce hierarchical taxonomy URL's, Can be enabled by setting 'hierarchical_url' to true upon taxonomy registration. See #12659
git-svn-id: http://svn.automattic.com/wordpress/trunk@15705 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-04 10:37:25 +00:00
nacin c6ff4fbaa9 Have wp_delete_category wrap wp_delete_term. Move wp_delete_category into wp-includes scope for consistency. fixes #15008, props blepoxp.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15690 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-03 07:29:44 +00:00
nacin 4e666d5d44 Move some post and taxonomy functions from admin/includes to wp-includes in preparation for QuickPress template tag. Moves get_tags_to_edit, get_terms_to_edit, get_default_post_to_edit, media_buttons, _media_button, get_upload_iframe_src. Also introduce get_media_buttons as a wrapper for media_buttons. props jorbin, see #14966.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15688 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-03 02:58:59 +00:00