Scott Taylor
0baa73f2e4
Apply `order` to each passed value for `orderby` in `WP_Query`:
...
* Since `orderby` in `WP_Query` can accept space-delimited sets, yet only one `order` value: when multiple values are passed (and `DESC` is the order), the default sort order `ASC` is being applied to all values before the last in the set.
* There is a unit test that sporadically fails since 3.6 in `tests/post/revision` due to multiple posts having the same `post_date` from being added so rapidly
* When ordering revisions in `wp_get_post_revisions()`, order by `post_date ID`
* Change the `order` value in `wp_get_post_revisions()` to `ASC`. This will produce SQL like: `ORDER BY $wpdb->posts.post_date ASC, $wpdb->posts.ID ASC`. Previously, this would have produced SQL like: `ORDER BY $wpdb->posts.post_date DESC`, and with the addition of ` ID`: `ORDER BY $wpdb->posts.post_date ASC, $wpdb->posts.ID DESC`. Clearly, wrong. The original SQL produced: `ORDER BY $wpdb->posts.post_date DESC`. As such, return the reversions in reverse order using `array_reverse()`. Not doing so would break "Preview Changes."
* Add unit tests to assert that all of this works.
* All existing unit tests pass with the change to ordering multiple `orderby`s in `WP_Query`.
* In the future, we should support independent `order` for each `orderby`, see #17065 .
Props SergeyBiryukov, wonderboymusic.
Fixes #26042 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28541 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 18:18:11 +00:00
Sergey Biryukov
b0b85cc484
Use correct variable. see [28534], [28538].
...
see #22400 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28540 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 17:39:22 +00:00
Scott Taylor
312ef7b264
These functions import `$wpdb` but do not use it.
...
See #27882 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28539 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 17:36:42 +00:00
Sergey Biryukov
ce653e1925
Remove redundant assignment. see [28379], [28534].
...
see #22400 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28538 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 17:34:34 +00:00
Sergey Biryukov
15588188e8
Fix inconsistent header underlining and spacing in background update emails.
...
fixes #28306 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28537 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 09:40:36 +00:00
Sergey Biryukov
3bd4762f9b
Twenty Fourteen: Bail early from Featured_Content::hide_featured_term() if term objects are unavailable.
...
fixes #28072 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28536 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 09:24:33 +00:00
Sergey Biryukov
9966795165
Use correct function name.
...
props ericlewis.
fixes #28329 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28535 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 07:58:26 +00:00
Scott Taylor
a0c78339fc
Fix some bad UI recursion in `wp_get_archives()` caused by [28379]. It appears that `$afterafter` was appropriately named.
...
See #22400 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28534 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-20 23:08:23 +00:00
Scott Taylor
6f4df85c8f
`WP_Query` was only missing one access modifier.
...
Add access modifier (`public`) to applicable class methods/members of `WP_Rewrite`. I am not brave enough to set some of the `var`s to `private` without more testing.
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28533 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 17:40:08 +00:00
Scott Taylor
707c313333
`WP_Date_Query` was only missing one access modifier.
...
Add access modifier (`public`) to all default widgets' class methods.
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28532 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 17:29:42 +00:00
Scott Taylor
dc1ada20c7
Upgrade `_WP_List_Table_Compat` to PHP5-style constructor.
...
Add `public` to methods/members of `WP_Role`.
Add `public` to methods/members of `WP_User` where appropriate. Don't set `private` where indicated until more study has occurred and tests have been written for compatibiliy with existing magic methods.
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28531 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 17:19:09 +00:00
Scott Taylor
be2e5f6fb5
`hackificator` doesn't like mixed single/double-quoted attributes. These were 2 lingering instances in the admin.
...
See #27881 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28530 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 17:09:42 +00:00
Scott Taylor
d261d0030a
In `WP_Filesystem_Base`, the constructor is a noop, so it shouldn't even be declared. Setting it implies that `parent::__construct()` should be called by its subclasses.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28529 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 16:45:42 +00:00
Scott Taylor
02eba613a5
Add access modifiers to `WP_User_Query`.
...
Add magic methods for BC: __get(), __set(), __isset(), __unset(), and
__call().
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28528 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 15:47:33 +00:00
Scott Taylor
3e054a2c7e
Add `public` access modifier to methods/members of `WP_Widget` and `WP_Widget_Factory`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28527 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 15:42:00 +00:00
Scott Taylor
02a28ec4e9
In `wpdb`, make some things explicitly `public`. Do not set anything to `private`. This would instantly blow up `hyperdb` in the wild.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28526 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 15:35:29 +00:00
Scott Taylor
1cbef26922
Add access modifiers to `WP_Text_Diff_Renderer_Table` that are compatible with its parent class. Some of the inline docs suggest access that, if implemented, would produce fatal errors.
...
Add magic methods for BC: __get(), __set(), __isset(), __unset(), and __call().
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28525 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 15:22:45 +00:00
Scott Taylor
daecbc9659
Classes that have `__set()` also need `__isset()` and `__unset()`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28524 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:51:35 +00:00
Scott Taylor
bf54ad6054
Add missing access modifiers to methods in `WP_Query`. Add magic methods for `__get()`, `__set()`, `__isset()`, `__unset()`, and `__call()`.
...
Add unit test for magic methods.
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28523 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:48:56 +00:00
Scott Taylor
5771dfbfa5
Add missing access modifiers to methods in `WP_Meta_Query`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28522 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:34:01 +00:00
Scott Taylor
77c6420969
Some classes with `__get()` method also need `__set()`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28521 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:31:00 +00:00
Scott Taylor
e76545e011
Fix fatal error in unit test.
...
See #27881 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28520 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:24:06 +00:00
Scott Taylor
d398ea806c
Add missing access modifiers to methods in `WP_Comment_Query`. Add a magic `__call()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28519 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:18:51 +00:00
Scott Taylor
ce917f0bc4
Add missing access modifiers to methods in `WP_Scripts` and `WP_Styles`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28518 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:16:39 +00:00
Scott Taylor
bd478a0135
Add missing access modifiers to methods in `WP_Dependencies` and `_WP_Dependency`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28517 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:13:24 +00:00
Scott Taylor
0e17651d7d
Add missing access modifiers to methods in `WP` and `WP_MatchesMapRegex`. Add magic `__call()` and `__get()` methods to `WP_MatchesMapRegex` for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28516 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:11:34 +00:00
Scott Taylor
ea0e965af3
Add missing access modifiers to methods in `wp_xmlrpc_server`. Add a magic `__call()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28515 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 06:08:04 +00:00
Scott Taylor
f716ff94e4
Add missing access modifiers to methods/members in `Walker` and subclasses. Add a magic `__get()` method.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28514 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:59:07 +00:00
Scott Taylor
f297dcba9a
Add missing access modifiers to methods/members in `WP_Image_Editor_*` classes.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28513 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:52:24 +00:00
Scott Taylor
9406ca3bb8
Add access modifiers to methods/members in `WP_HTTP_IXR_Client`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28512 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:50:19 +00:00
Scott Taylor
0401ec1c9f
Add access modifiers to methods/members in `WP_Error`. Add a magic `__get()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28511 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:49:22 +00:00
Scott Taylor
26af443ade
Add access modifiers to methods/members in `WP_Embed`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28510 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:46:56 +00:00
Scott Taylor
8bb3b642ec
Add missing access modifiers to methods/members in `WP_Customize_*`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28509 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:44:49 +00:00
Scott Taylor
ddce296dd3
Add access modifier to methods/members in `WP_Ajax_Response`. Adds a magic `__get()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28508 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:40:11 +00:00
Scott Taylor
4a5a7cb88a
Add access modifier to methods/members in `WP_oEmbed`. Adds a magic `__call()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28507 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:36:38 +00:00
Scott Taylor
0d5768f0f4
Add access modifier to methods of HTTP classes. There are no new private or protected methods, so no need for `__call()`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28506 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:33:08 +00:00
Scott Taylor
8c2ccf6d7c
Add access modifiers to methods/members in `WP_Feed_Cache`, `WP_SimplePie_File`, and `WP_Feed_Cache_Transient`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28505 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:26:48 +00:00
Scott Taylor
1d13dc8a85
Add access modifiers to methods/members in `Walker_Category` and `Walker_CategoryDropdown`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28504 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:22:38 +00:00
Scott Taylor
599dff5c3d
Add access modifiers to methods/members in `WP_Roles`. Add a magic `__call()` method for BC.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28503 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:19:36 +00:00
Scott Taylor
241d1a4d99
Add access modifiers to methods/members in `WP_Object_Cache`. Add a magic `__get()` method for BC.
...
See #27881 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28502 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:15:20 +00:00
Scott Taylor
b185ac51b2
In `wp_list_bookmarks()`, `$categorize` should now be `$r['categorize]`.
...
See #22400 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28501 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:10:45 +00:00
Scott Taylor
e43d2a73d8
Fix some `hackificator` odds and ends in `wp-admin`:
...
* `wp-activate.php` and `wp-admin/themes.php` don't need the closing PHP tag
* Switch single quotes for HTML attribute values to double in a few places
* Convert `include_once file.php` syntax to `include_once( 'file.php' )`
* Add access modifiers to methods/members in: `_WP_List_Table_Compat`, `Walker_Nav_Menu_Edit`, `Walker_Nav_Menu_Checklist`, `WP_Screen`, `Walker_Category_Checklist`
* `edit_user()` doesn't need to import the `$wpdb` global
* `wp_list_widgets()` doesn't need to import the `$sidebars_widgets` global
* switch/endswitch syntax is not supported in Hack
* A `<ul>` in `wp-admin/users.php` is unclosed
See #27881 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28500 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 05:03:44 +00:00
Drew Jaynes (DrewAPicture)
7b2c87df9a
Improve inline documentation of default arguments for `post_format_meta_box()`, `post_tags_meta_box()`, and `post_categories_meta_box()`.
...
See #28298 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28499 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 03:22:21 +00:00
Drew Jaynes (DrewAPicture)
f228c5b16e
Improve inline documentation of default arguments for `the_title_attribute()`.
...
See #28298 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28498 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 02:27:08 +00:00
Scott Taylor
eef0d99ed8
`hackificator` doesn't like mixed quote styles in some generated HTML. The switch from single to double allows these files to be parsed.
...
See #27881 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28497 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:58:28 +00:00
Scott Taylor
afe33f0f68
Add access modifier (`public`) to methods and members of `WP_Upgrader` and its subclasses.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28496 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:28:10 +00:00
Scott Taylor
17cabb1d8e
Add access modifier (`public`) to methods and members of `WP_Upgrader_Skin` and its subclasses.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28495 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:22:55 +00:00
Scott Taylor
b1a09cf65d
Add access modifiers to methods and members of `WP_Users_List_Table`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28494 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:18:46 +00:00
Scott Taylor
d6a3c2a0de
Add access modifiers to methods and members of list table classes:
...
* `WP_List_Table` is the base class that implements `__get()` and `__call()` for BC
* Adds unit tests to confirm that subclasses properly inherit magic methods
* Add modifiers to subclasses: `WP_Links_List_Table`, `WP_Media_List_Table`, `WP_MS_Sites_List_Table`, `WP_MS_Themes_List_Table`, `WP_MS_Users_List_Table`, `WP_Plugin_Install_List_Table`, `WP_Plugins_List_Table`, `WP_Posts_List_Table`, `WP_Terms_List_Table`, `WP_Theme_Install_List_Table`, `WP_Themes_List_Table`
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28493 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:16:16 +00:00
Scott Taylor
99c99b77e3
Add access modifier (`public`) to methods in `WP_Importer`.
...
See #27881 , #22234 .
git-svn-id: https://develop.svn.wordpress.org/trunk@28492 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 00:19:00 +00:00