Commit Graph

15756 Commits

Author SHA1 Message Date
Boone Gorges
cc8f18b698 Add tests for wp_list_categories() CSS class generation.
See #16497.
Built from https://develop.svn.wordpress.org/trunk@31026


git-svn-id: http://core.svn.wordpress.org/trunk@31007 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-03 02:23:24 +00:00
Boone Gorges
a0d1faa383 In Walker_Category, don't generate list elements for empty cat names.
This change allows the 'list_cats' filter to be used to suppress certain
items in category lists, without creating invalid or superfluous markup.

Props samo9789.
Fixes #16792.
Built from https://develop.svn.wordpress.org/trunk@31025


git-svn-id: http://core.svn.wordpress.org/trunk@31006 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-03 02:05:22 +00:00
Boone Gorges
1b63ada83d Introduce 'name' parameter for get_terms().
This enhancement requires a modification in the way that `wp_dropdown_categories()`
prepares its arguments for `get_terms()`, so that its unrelated 'name' param is
not mistaken for the new 'name' argument in `get_terms()`.

Props danielbachhuber.
Fixes #30611.
Built from https://develop.svn.wordpress.org/trunk@31024


git-svn-id: http://core.svn.wordpress.org/trunk@31005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-02 21:34:23 +00:00
Andrew Ozz
e0189c3686 Move the (recently added) .notice admin notices below the first H2, same as the .updated and .error notices. Props sippis, fixes #30885.
Built from https://develop.svn.wordpress.org/trunk@31023


git-svn-id: http://core.svn.wordpress.org/trunk@31004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-02 18:52:23 +00:00
Andrew Ozz
fe0bf57deb Fix the background color in the auth. check modal. Props melchoyce, fixes #30278.
Built from https://develop.svn.wordpress.org/trunk@31022


git-svn-id: http://core.svn.wordpress.org/trunk@31003 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-02 17:21:22 +00:00
Boone Gorges
77e635f8fe Add tests for wp_delete_object_term_relationships().
See #30879.
Built from https://develop.svn.wordpress.org/trunk@31021


git-svn-id: http://core.svn.wordpress.org/trunk@31002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-02 14:03:26 +00:00
Scott Taylor
aa26b4c1a0 If you set '_wp_page_template' for a post, and then switch to a theme that doesn't support the template, subsequent calls to wp_insert_post() will bail early without running a plethora of hooks. This shouldn't happen. We should set the template to 'default' and continue through the rest of the function. The function will still bail if $wp_error is true via wp_insert_post( $arr, true ).
Props nofearinc.
Fixes #25334.

Built from https://develop.svn.wordpress.org/trunk@31020


git-svn-id: http://core.svn.wordpress.org/trunk@31001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-01 20:35:30 +00:00
Scott Taylor
5e4941023b WP_List_Table's constructor registers an 'admin_footer' callback when AJAX is enabled. As such, if you create multiple instances of the class, you get multiple JS blobs on the page when the callbacks fire. Extra instances get made when wp_comment_reply() invokes the class constructor without checking for the existing instance via the $wp_list_table global.
We shall check the `$wp_list_table` global in `wp_comment_reply()`.

Props sorich87.
Fixes #17413.

Built from https://develop.svn.wordpress.org/trunk@31019


git-svn-id: http://core.svn.wordpress.org/trunk@31000 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-01 19:55:35 +00:00
Scott Taylor
a5593a64d3 More-specific docs for wp_embed_handler_youtube().
Fixes #30711.

Built from https://develop.svn.wordpress.org/trunk@31018


git-svn-id: http://core.svn.wordpress.org/trunk@30999 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-01 19:21:27 +00:00
Sergey Biryukov
f3ef425b11 Update license copyright year to 2015.
props valendesigns.
fixes #30877.
Built from https://develop.svn.wordpress.org/trunk@31017


git-svn-id: http://core.svn.wordpress.org/trunk@30998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-01 12:25:26 +00:00
Scott Taylor
952a5c9971 Support chromeless Vimeo via MEjs:
* Bump MediaElement script loader versions to 2.16.2 - missed in [30634], oops!
* Add `Froogaloop` to `js/mediaelement` scripts for Vimeo
* Check for Vimeo in the same locations that YouTube is checked
* Dynamically load Froogaloop script in admin when editing a TinyMCE view
* Edit MediaElement to call `mejs.$.extend` instead of `$.extend` in `mejs.HtmlMediaElementShim.createPlugin()`, since `$` is not available via WP's jQuery (I will report this upstream):
6f9a78e008/src/js/me-shim.js (L631)

Fixes #29267.

Built from https://develop.svn.wordpress.org/trunk@31016


git-svn-id: http://core.svn.wordpress.org/trunk@30997 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 20:41:24 +00:00
Boone Gorges
f1a4fd6e85 Support array values for post-related parameters in WP_Comment_Query.
Props nprasath002, c3mdigital, ianmjones.
Fixes #20006.
Built from https://develop.svn.wordpress.org/trunk@31015


git-svn-id: http://core.svn.wordpress.org/trunk@30996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 19:38:22 +00:00
Boone Gorges
36f36dca77 In remove_all_filters(), only remove callbacks that match the $priority parameter.
Props GeertDD, valendesigns.
Fixes #20920.
Built from https://develop.svn.wordpress.org/trunk@31014


git-svn-id: http://core.svn.wordpress.org/trunk@30995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 19:07:24 +00:00
Scott Taylor
586c1ac7bc Fix docs for WP_User::allcaps:
The `allcaps` property of the `WP_User` class represents all of the caps of the user, not the caps of the user's role. Introduced in [26126].

Props dlh.
Fixes #30852.

Built from https://develop.svn.wordpress.org/trunk@31013


git-svn-id: http://core.svn.wordpress.org/trunk@30994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 18:15:23 +00:00
Scott Taylor
96558ac3c3 Update/fix inline docs for update_object_term_cache().
Props DrewAPicture.
Fixes #30731.

Built from https://develop.svn.wordpress.org/trunk@31012


git-svn-id: http://core.svn.wordpress.org/trunk@30993 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 18:12:26 +00:00
Scott Taylor
7f94333084 Correct a typo in wp-includes/post-thumbnail-template.php.
Props ixkaito.
Fixes #30867.

Built from https://develop.svn.wordpress.org/trunk@31011


git-svn-id: http://core.svn.wordpress.org/trunk@30992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 18:09:25 +00:00
Aaron Jorbin
7ea306dd9d Set the type attribute of the buttons for logging out of all sessions to buttons
By not setting this attribute, the buttons default to submit and as the first
submit button on the page, it causes pressing the enter key to log you out of
all sessions. This change restores the pre 4.1 behavior where pressing enter
while focused on a form field submits the form.

props ocean90
fixes #30871 for trunk


Built from https://develop.svn.wordpress.org/trunk@31010


git-svn-id: http://core.svn.wordpress.org/trunk@30991 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 17:33:24 +00:00
Boone Gorges
a170302b36 Back up and restore dropins during get_dropins() tests.
This change ensures that the `get_dropins()` tests don't detect any actual
dropins that you might be running on your develop.wordpress installation.

Props valendesigns.
Fixes #30860.
Built from https://develop.svn.wordpress.org/trunk@31009


git-svn-id: http://core.svn.wordpress.org/trunk@30990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 15:01:22 +00:00
Andrew Nacin
bc60e63518 Use correct function name in docs for get_plugin_data().
props eliorivero.
fixes #30699.

Built from https://develop.svn.wordpress.org/trunk@31008


git-svn-id: http://core.svn.wordpress.org/trunk@30989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 08:08:22 +00:00
Dion Hulse
e165f2caec Add a revision number to $wp_version for nightly update purposes. See [30411]
Built from https://develop.svn.wordpress.org/trunk@31007


git-svn-id: http://core.svn.wordpress.org/trunk@30988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-31 05:35:22 +00:00
Boone Gorges
e99c00492b In wp_dropdown_categories(), allow the term field used to populate option valuesto be specified.
The new 'value_field' parameter makes it possible to set term slugs (or some
other term property) as the 'value' attribute of the option elements generated
by `wp_dropdown_categories()`. This additional flexibility reduces the effort
required to translate term_id to other term fields when processing form
submissions that include values from taxonomy dropdowns. See #30865 for a
use case.

Props collinsinternet.
Fixes #30306.
Built from https://develop.svn.wordpress.org/trunk@31006


git-svn-id: http://core.svn.wordpress.org/trunk@30987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-30 21:31:23 +00:00
Boone Gorges
4825bbcf31 Use proper hash notation for wp_dropdown_categories() docblock.
See #30306.
Built from https://develop.svn.wordpress.org/trunk@31005


git-svn-id: http://core.svn.wordpress.org/trunk@30986 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-30 20:49:21 +00:00
Andrew Nacin
504eb9aa0d XML-RPC: Send 405 Method Not Allowed for GET requests.
props maxcutler.
fixes #20986.

Built from https://develop.svn.wordpress.org/trunk@31004


git-svn-id: http://core.svn.wordpress.org/trunk@30985 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-30 20:41:23 +00:00
Sergey Biryukov
ed7033ec9b Pass the $adjacent parameter to the "{$adjacent}_post_link" filter.
props ankit.gade@rtcamp.com, kpdesign.
fixes #30440.
Built from https://develop.svn.wordpress.org/trunk@31000


git-svn-id: http://core.svn.wordpress.org/trunk@30982 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-30 06:57:23 +00:00
Sergey Biryukov
200ca064b0 Correct $taxonomies parameter description in get_terms() filters.
props dlh.
fixes #30851.
Built from https://develop.svn.wordpress.org/trunk@30994


git-svn-id: http://core.svn.wordpress.org/trunk@30976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-28 01:44:24 +00:00
Boone Gorges
fb54c6d7c9 Pass $resource_type to 'get_ancestors' filter.
The `$resource_type` argument was added to the `get_ancestors()` function in
[30141]. In that changeset, the documentation for the filter was updated to
indicate that it would receive `$resource_type` as a param, but the filter
itself was not updated accordingly.

Props tmatsuur, DrewAPicture.
Fixes #30843.
Built from https://develop.svn.wordpress.org/trunk@30993


git-svn-id: http://core.svn.wordpress.org/trunk@30975 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-26 21:29:22 +00:00
Dominik Schilling
93605deef5 Customizer: Improve IE 8 compatibility.
* Use square bracket notation for `default` keywords.
* Use Underscores `indexOf` for arrays.

props westonruter, ocean90.
fixes #30781 for trunk.
Built from https://develop.svn.wordpress.org/trunk@30991


git-svn-id: http://core.svn.wordpress.org/trunk@30973 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-23 17:05:26 +00:00
Andrew Ozz
441b47b28f TinyMCE wpView: when clicking on the Edit button, move the focus back to the editor before opening the modal. This is needed for IE so TinyMCE can save the proper DOM "bookmark", and makes it possible to move the focus to the modal after it is opened.
See #30817.
Built from https://develop.svn.wordpress.org/trunk@30986


git-svn-id: http://core.svn.wordpress.org/trunk@30972 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-22 21:31:26 +00:00
Boone Gorges
b806668e71 In wp_update_term(), limit duplicate slug checks to the same taxonomy as the updated term.
In 4.1 [30240], `wp_insert_term()` was modified to allow the creation of terms
with duplicate slugs, as long as the terms are in different taxonomies.
`wp_update_term()` didn't get the corresponding modification, with the result
that term updates fail when the term being updated shares a slug with an older
term, regardless of that older term's taxonomy.

Props ipm-frommen.
Fixes #30780 for trunk.
Built from https://develop.svn.wordpress.org/trunk@30985


git-svn-id: http://core.svn.wordpress.org/trunk@30971 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-22 15:33:25 +00:00
Scott Taylor
786caa4d55 Correct the @param docs for arguments that are truthy/falsey.
See #30799.

Built from https://develop.svn.wordpress.org/trunk@30983


git-svn-id: http://core.svn.wordpress.org/trunk@30969 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-20 23:04:23 +00:00
Scott Taylor
5eb5afac34 For clarity, initialize some arrays that previously were only assigned via short circuit in loops.
See #30799.

Built from https://develop.svn.wordpress.org/trunk@30982


git-svn-id: http://core.svn.wordpress.org/trunk@30968 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-20 22:47:22 +00:00
Scott Taylor
42f5acd869 Improve some docs for @param. Remove an unneeded $wpdb global import.
See #30799.

Built from https://develop.svn.wordpress.org/trunk@30979


git-svn-id: http://core.svn.wordpress.org/trunk@30965 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-20 20:56:22 +00:00
Boone Gorges
e1ebba28d4 Update individual term caches in get_terms().
This was removed in [29915] as part of the attempt to add cache support to
`get_term_by()`. When that support was removed in [30900], it was not properly
restored.

This changeset includes a unit test to verify that the cache is properly primed
for terms found in `get_terms()`, as well as tests to verify the other cache
setting that was touched by [30900].

Fixes #30749. See #21760.
Built from https://develop.svn.wordpress.org/trunk@30954


git-svn-id: http://core.svn.wordpress.org/trunk@30942 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-17 16:39:24 +00:00
Mark Jaquith
0cf92119eb Revert [30036].
see #18035
Built from https://develop.svn.wordpress.org/trunk@30912


git-svn-id: http://core.svn.wordpress.org/trunk@30902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 17:35:23 +00:00
Scott Taylor
f492a8f7dc In response to regressions on .com, fix MEjs styles for screen reader text and overflow on the volume slider.
Props obenland.
See #30281.

Built from https://develop.svn.wordpress.org/trunk@30907


git-svn-id: http://core.svn.wordpress.org/trunk@30897 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 15:13:24 +00:00
Boone Gorges
6ebb326c54 Remove caching for get_term_by() calls.
The new cache group scheme causes term invalidation to be overly broad, so
that busting the cache for one term will bust the cache for all terms in the
taxonomy. We'll have another go at more focused use of the 'last_changed'
incrementor in a future release.

Reverts [29915], [30073], [30080], [30108], [30112].
See #21760.
Built from https://develop.svn.wordpress.org/trunk@30900


git-svn-id: http://core.svn.wordpress.org/trunk@30890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 13:27:22 +00:00
Dominik Schilling
1f6e85e60f Customizer: Export Preview instance to wp.customize.preview.
see #30409, #30726.
Built from https://develop.svn.wordpress.org/trunk@30891


git-svn-id: http://core.svn.wordpress.org/trunk@30881 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 11:53:22 +00:00
Andrew Nacin
8c3027c3c7 Call it 'Distraction-free writing mode' and update the help string. fixes #30657.
Built from https://develop.svn.wordpress.org/trunk@30890


git-svn-id: http://core.svn.wordpress.org/trunk@30880 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 10:07:23 +00:00
Andrew Nacin
23f4b0f62f Updates to the 'Log out everywhere' implementation.
* Include a message and a disabled button when you're only logged in at one location.
 * Avoid leaking the session token in HTML.
 * Simplify, simplify, simplify.

see #30264.

Built from https://develop.svn.wordpress.org/trunk@30888


git-svn-id: http://core.svn.wordpress.org/trunk@30878 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 09:15:23 +00:00
Dion Hulse
1d59ca9004 Add braces around a Docblock in an if statement, although not required by PHP, this is required by our coding standards for readability.
Introduced in 3.9 with r27365
See #25905

Built from https://develop.svn.wordpress.org/trunk@30886


git-svn-id: http://core.svn.wordpress.org/trunk@30876 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 05:52:23 +00:00
Dominik Schilling
fcb00b75e2 Customizer: Add _wp_attachment_is_custom_background meta to uploaded background images.
Adds `$type` property to `WP_Customize_Background_Image_Control` (PHP) and introduces `wp.customize.BackgroundControl` (JS).

see #30707.
Built from https://develop.svn.wordpress.org/trunk@30885


git-svn-id: http://core.svn.wordpress.org/trunk@30873 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 23:28:23 +00:00
John Blackbourn
618b673470 Clarify the behaviour of the wp_editor_set_quality and jpeg_quality filters.
Props DH-Shredder
See #29856

Built from https://develop.svn.wordpress.org/trunk@30874


git-svn-id: http://core.svn.wordpress.org/trunk@30863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 21:43:22 +00:00
Dominik Schilling
4652717828 Customizer: Remove date filter from the Header/Background Image upload frames.
Adds an option to `wp.media.view.AttachmentsBrowser` to hide the date filter added in [29813].

see #30689.
Built from https://develop.svn.wordpress.org/trunk@30872


git-svn-id: http://core.svn.wordpress.org/trunk@30862 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 20:27:22 +00:00
Andrew Nacin
180c596d7b Rename _wp_clear_update_cache() to wp_clean_update_cache().
This makes it match most cache-clearing functions, including the ones it wraps. Also no need for it to be prefixed as "private."

wp_clean_plugins_cache() doesn't always exist, so as a quick fix, clear the transient we care to clear.

see #30369.

Built from https://develop.svn.wordpress.org/trunk@30856


git-svn-id: http://core.svn.wordpress.org/trunk@30846 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 08:55:22 +00:00
Andrew Nacin
741e0ec6de No need for wp_get_password_hint() to be prefixed as if it is private.
see #21243.

Built from https://develop.svn.wordpress.org/trunk@30855


git-svn-id: http://core.svn.wordpress.org/trunk@30845 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 08:34:23 +00:00
Andrew Nacin
498be1cae9 Avoid repeatedly calling is_tax( 'post_format', '...' ) in get_the_archive_title().
see #21995.

Built from https://develop.svn.wordpress.org/trunk@30854


git-svn-id: http://core.svn.wordpress.org/trunk@30844 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-15 07:32:26 +00:00
Dominik Schilling
bb879d101b Customizer: Re-add the possibility to remove and restore a default background image.
see #21483.
fixes #30683 for trunk.
Built from https://develop.svn.wordpress.org/trunk@30849


git-svn-id: http://core.svn.wordpress.org/trunk@30839 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-14 19:37:22 +00:00
Dominik Schilling
9a599e4093 Customizer: Don't escape control descriptions in JavaScript templates.
fixes #30682 for trunk.
Built from https://develop.svn.wordpress.org/trunk@30847


git-svn-id: http://core.svn.wordpress.org/trunk@30837 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-14 19:24:23 +00:00
Boone Gorges
5eeea164ef In WP_Meta_Query, interpret 'value' correctly when used with EXISTS/NOT EXISTS.
As in earlier versions, EXISTS with a value is equivalent to '=', while NOT
EXISTS should always ignore 'value'.

Props barrykooij.
Fixes #30681 for trunk.
Built from https://develop.svn.wordpress.org/trunk@30846


git-svn-id: http://core.svn.wordpress.org/trunk@30836 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-14 19:01:26 +00:00
Andrew Ozz
9f2fc255f8 TinyMCE: add another Edit translatable string for the tooltip of the Edit button on the image toolbar. Props pavelevap, see #30694.
Built from https://develop.svn.wordpress.org/trunk@30839


git-svn-id: http://core.svn.wordpress.org/trunk@30829 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-13 00:47:22 +00:00