Commit Graph

482 Commits

Author SHA1 Message Date
markjaquith
e55cf70e35 Do not attempt to clear post cache for post ID 0... that will recursively destroy your server
git-svn-id: http://svn.automattic.com/wordpress/trunk@15503 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-08-18 06:50:53 +00:00
nacin
34e43c7bce Doc update for [15402]. fixes #14301.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15449 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-07-21 00:50:01 +00:00
ryan
8513fbef01 Sanity check properties in wp_get_single_post(). Props filosofo. fixes #13904 for 3.1
git-svn-id: http://svn.automattic.com/wordpress/trunk@15405 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-07-13 21:30:09 +00:00
nacin
5fb64228d8 Have wp_set_post_terms return wp_set_object_terms. fixes #14301.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15402 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-07-13 21:01:48 +00:00
dd32
a14d289755 Alot more tabs. Props jacobsantos & Viper007bond. See #14147
git-svn-id: http://svn.automattic.com/wordpress/trunk@15355 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-30 00:05:18 +00:00
ryan
088aff8699 Use get_post_types() to create list of hierarchical post types. fixes #14079 for 3.1
git-svn-id: http://svn.automattic.com/wordpress/trunk@15348 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-29 14:10:54 +00:00
ryan
d053a4f707 Avoid var name collision. see #13929
git-svn-id: http://svn.automattic.com/wordpress/trunk@15269 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-16 21:46:42 +00:00
ryan
bfd7a6b75b Retern variable to avoid notice in PHP 4.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15265 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-16 19:11:44 +00:00
ryan
c614b6d0a2 Deprecate is_term, is_taxonomy, is_post_type for *_exists(). Props nacin. fixes #13747
git-svn-id: http://svn.automattic.com/wordpress/trunk@15220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-11 15:53:41 +00:00
nacin
af612805e8 Move 'helps' argument to the taxonomy labels object. Also move over help_nojs and help_cloud, both introduced in 3.0. This adds three new core labels for non-hierarchical taxonomies, for tweaking the meta box strings. fixes #13805.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15190 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-10 16:07:33 +00:00
ryan
930711454f Fix global post stomping in get_post(). Turn get_page() into an alias of get_post(). Props westi. fixes #13753
git-svn-id: http://svn.automattic.com/wordpress/trunk@15188 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-10 14:55:26 +00:00
ryan
a353af5a41 phpdoc fix. Props duck_
git-svn-id: http://svn.automattic.com/wordpress/trunk@15169 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-08 13:24:20 +00:00
nacin
332c2773e0 Use show_in_nav_menus for attachments. Also add it to register_taxonomy for consistency and have it default to public, not show_ui, like post types. see #13621.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-29 16:46:46 +00:00
nacin
844226a1d8 Some inline doc updates for get_post_type_capabilities and get_post_type_labels. props MichaelH, fixes #13573.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-27 12:44:08 +00:00
ryan
1a552dd029 Strip trailing whitespace
git-svn-id: http://svn.automattic.com/wordpress/trunk@14924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-26 02:42:15 +00:00
nacin
16f79e5377 Remove unused/duplicated/undocumented post type object label. see #13539
git-svn-id: http://svn.automattic.com/wordpress/trunk@14903 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-25 19:25:27 +00:00
nacin
479d1d3617 Fix typo. props rovo89, fixes #13494.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-25 18:59:20 +00:00
ryan
432d56981e Don't set default category when saving an auto-draft. fixes #13531
git-svn-id: http://svn.automattic.com/wordpress/trunk@14883 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-25 14:43:39 +00:00
nacin
10562923ae Remove now-unused post_type_object->labels>edit, which was 'Edit' (with context). see #12968, see #11274.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14857 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-24 21:19:29 +00:00
dd32
378f68a0a0 Introduce a 'post_updated' action, Fires when a post is updated, Post ID, Current and Previous post objects are passed. Updatewp_check_for_changed_slugs() to use new hook. See #12473
git-svn-id: http://svn.automattic.com/wordpress/trunk@14814 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-23 07:49:21 +00:00
ryan
f0076eed1c Set show_ui to true for post and page. Exclude _builtin = true from areas where we need to special case builtin types. fixes #13403
git-svn-id: http://svn.automattic.com/wordpress/trunk@14713 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-17 16:39:36 +00:00
westi
01389755c7 Make get_attachment_metadata() loop safe.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14699 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-16 21:00:00 +00:00
nacin
5463205114 Remove default_comment_status_pages setting. Reverts [14451], [14448] for 3.0. see #12991.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14650 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-15 04:56:56 +00:00
ryan
4f88b4bf60 register_post_type phpdoc updates. Props michaelh. fixes #13398
git-svn-id: http://svn.automattic.com/wordpress/trunk@14648 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-14 22:26:07 +00:00
nbachiyski
c1dea00b62 Keep label as a quick way to set up a taxonomy/post type, without diving into the labels array. Deprecate singular_label while there. Props nacin. Fixes #13357
git-svn-id: http://svn.automattic.com/wordpress/trunk@14619 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-14 02:13:49 +00:00
nbachiyski
4cf46b6d96 I18n for custom taxonomies. Fixes #13357
git-svn-id: http://svn.automattic.com/wordpress/trunk@14614 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-14 00:34:04 +00:00
ryan
067fc117cb Add show_in_nav_menus flag to post type registration. Props williamsba1. fixes #13144
git-svn-id: http://svn.automattic.com/wordpress/trunk@14602 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-13 17:29:45 +00:00
nacin
af91e5264a Move taxonomy object properties for capabilities into a cap object. Capabilities can be specified via ['capabilities'] (an array keyed by the generic cap name) for register_taxonomy. fixes #13358.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14593 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-13 04:10:17 +00:00
nacin
e15c230ffc Unset capabilities property when we're done. see #13358.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14589 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-12 21:17:38 +00:00
nacin
1cb8b7d994 Fix typos. see #13358.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14587 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-12 20:57:47 +00:00
nacin
7734a07cb2 Move post type object capabilities to a 'cap' object. Allow them to be initialized via the 'capabilities' key (an array) when registering support for the post type. Caps are now referred to by the name of the cap as if it was a post, i.e. ->cap->edit_post. see #13358.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14585 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-12 20:45:18 +00:00
nacin
b2d3b7efa2 Use correct cap check. see #13358.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-12 19:39:30 +00:00
nbachiyski
46afe7c285 I18n for custom post type labels. Props demetris, dimadin. Fixes #12968
git-svn-id: http://svn.automattic.com/wordpress/trunk@14571 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-11 19:52:50 +00:00
ryan
c7f520240c Don't set/get tags or categories for post types that do not support them. fixes #13346
git-svn-id: http://svn.automattic.com/wordpress/trunk@14561 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-11 16:28:00 +00:00
ryan
66502fba1a Allow turning off object_term and postmeta cache updates. Turn off object_term updates in the wp_get_nav_menu_items() get_posts() query to avoid useless taxonomy query.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14528 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-10 00:58:39 +00:00
nacin
2eab801eec Simplify is_post_type and is_post_type_hierarchical. Make them work like their taxonomy counterparts. see #12588.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14521 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-08 22:10:28 +00:00
westi
5ac646d37d Restore the strtotime(). See #9285.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14507 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-07 20:57:23 +00:00
nacin
1c05c2f6e2 Fix to is_post_type. props scribu, fixes #12588.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14498 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-07 04:57:23 +00:00
westi
390a40981f Improve cross DST future post publishing behaviour to try and publish at the correct time if we have PHP5 timezone support available to help. Fixes #9285 props technosailor.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14487 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-06 20:40:29 +00:00
nacin
6c69044070 Prevent ambiguous table aliases in wp_post_mime_type_where. props stephdau, jfarthing84, fixes #12750.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14478 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-06 18:03:05 +00:00
wpmuguru
96153a63ae add default comment status setting for pages, props messenlehner, see #12991
git-svn-id: http://svn.automattic.com/wordpress/trunk@14448 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 19:31:24 +00:00
wpmuguru
1beb7406da use reset vs offset 0, props scribu, see #13246
git-svn-id: http://svn.automattic.com/wordpress/trunk@14447 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 18:41:38 +00:00
wpmuguru
94e529cee3 add export property to post types, see #10317
git-svn-id: http://svn.automattic.com/wordpress/trunk@14441 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 16:23:25 +00:00
nacin
86c5154557 Clean up whitespace in status/PT/tax registration.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14432 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 06:13:28 +00:00
dd32
c843c7edf3 Remove accidental code. See #10122
git-svn-id: http://svn.automattic.com/wordpress/trunk@14431 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 05:48:08 +00:00
wpmuguru
abed02b32d use homeurl(), props PeteMall, see #9008
git-svn-id: http://svn.automattic.com/wordpress/trunk@14429 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-04 00:28:29 +00:00
dd32
2bbdd19973 Handle $_POST containing an empty term array, Fixes saving of deselecting all hierarchical terms. Fixes #10122
git-svn-id: http://svn.automattic.com/wordpress/trunk@14426 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-03 23:35:22 +00:00
ryan
7b7243d94a Strip trailing whites.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14404 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-03 20:26:11 +00:00
nacin
aca357b327 Handle page hierarchy when showing the sample permalink. props duck_, fixes #12327.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14399 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-03 20:10:26 +00:00
nacin
7ef5f08d00 Update object term cache for custom post types. props scribu, fixes #12989.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14310 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-04-29 20:43:59 +00:00