Commit Graph

34148 Commits

Author SHA1 Message Date
Dion Hulse
5d9cdca116 IXR: Use a strict comparison to ensure that a non-numerically-indexed array is not incorrectly matched as a numeric array.
See #36586


git-svn-id: https://develop.svn.wordpress.org/trunk@37244 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-19 06:12:42 +00:00
Sergey Biryukov
8b8b0909d4 Login/Registration: Add login_header action that fires in the login page header after the body tag is opened and complements login_footer.
Props borkweb, iamfriendly, voldemortensen.
Fixes #22139.

git-svn-id: https://develop.svn.wordpress.org/trunk@37243 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 23:53:34 +00:00
Andrew Ozz
56a22f8c74 TinyMCE: update to 4.3.10, changelog: https://github.com/tinymce/tinymce/blob/master/changelog.txt. Fixes #36545 for trunk.
git-svn-id: https://develop.svn.wordpress.org/trunk@37242 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 21:45:46 +00:00
Jeremy Felt
d72c2197ed Tests: Add test for multiple site path segments in bootstrap
This fixes a `@todo` that has been around since the introduction of these tests in [28910].

See #36566.


git-svn-id: https://develop.svn.wordpress.org/trunk@37241 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 03:38:11 +00:00
Boone Gorges
07fa16713d Include taxonomy term metadata in WXR export.
Because term XML nodes now include termmeta and can thus be much larger, this
changeset also includes adds some newlines and indentation to make the XML
easier to read.

Props Chouby.
See #34062.

git-svn-id: https://develop.svn.wordpress.org/trunk@37240 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 03:37:04 +00:00
Jeremy Felt
fa92abf4f3 Tests: Add missing params to doc blocks
* These should have been included in [37236] and [37238].
* Simplifies parameter names in `test_get_network_by_path()`

See #36566.


git-svn-id: https://develop.svn.wordpress.org/trunk@37239 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 03:26:48 +00:00
Jeremy Felt
bf5abfd9d0 Tests: Use a data provider to test multisite's bootstrap
This also helps to get things in order before the introduction of a more testable multisite bootstrap function in #34941.

A `@todo` has been temporarily removed, to be re-introduced as a working test.

See #36566.


git-svn-id: https://develop.svn.wordpress.org/trunk@37238 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 03:18:51 +00:00
Jeremy Felt
5e2f936c28 Tests: Use a data provider in get_site_by_path() tests
See #36566, #34941.


git-svn-id: https://develop.svn.wordpress.org/trunk@37237 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 02:38:49 +00:00
Jeremy Felt
48ba391b9b Tests: Use a data provider to test get_network_by_path()
See #36566, #34941.


git-svn-id: https://develop.svn.wordpress.org/trunk@37236 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 02:00:36 +00:00
Sergey Biryukov
a3eb12ddbb Docs: Clarify that is_tax() and WP_Query::is_tax() return false for built-in taxonomies (category and tag archives).
Props theMikeD.
Fixes #36331.

git-svn-id: https://develop.svn.wordpress.org/trunk@37235 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 01:43:54 +00:00
Jeremy Felt
e4efe5fac9 Tests: Share test fixtures in multisite bootstrap tests
* Remove unnecessary `setUp` and `tearDown` methods.
* Create networks and sites in `wpSetupBeforeClass` to share throughout.
* Destroy networks and sites in `wpTearDownAfterClass` to unpollute.

See #36566, #34941.


git-svn-id: https://develop.svn.wordpress.org/trunk@37234 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 01:37:47 +00:00
Jeremy Felt
89877c5941 Tests: Improve get_blog_count() tests
* Use `wp_update_network_counts()` to update the database with the most current data before testing.
* Use `wp_update_network_counts()` to update the database with the most current data after deleting the sites created during the test.
* Create only 1 extra site in each test rather than 4. This shaves several seconds off the test time.
* Stop testing for an extra count now that we update the network counts properly. Previously we looked at `$site_count_start + 9` rather than 8. Now this is `+ 1`, which aligns with the actual number of sites created.
* Test 3 explicit conditions - default, filter applied as `true`, and filter applied as `false`.
* Reset data before testing assertion to avoid a suspended state.

See #36566.


git-svn-id: https://develop.svn.wordpress.org/trunk@37233 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 01:28:56 +00:00
Sergey Biryukov
2f3c1769fa Theme Editor: After [37217], add other embed templates to file descriptions.
Props Frozzare.
Fixes #34561. See #34561.

git-svn-id: https://develop.svn.wordpress.org/trunk@37232 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-18 01:04:15 +00:00
Andrea Fercia
8309ab055f Accessibility: change the close "X" in the Media "Attach to existing content" modal in a button.
Props joedolson.

Fixes #36554.

git-svn-id: https://develop.svn.wordpress.org/trunk@37231 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 16:57:54 +00:00
Andrea Fercia
112337ce75 Accessibility: Customizer, improve UI controls in customize.php
- makes the mobile preview/customize toggle a button
- changes the "Close" link hidden text from 'Cancel' to 'Close the Customizer and go back to the previous page'
- adds a missing `type="button"` attribute
- removes unnecessary `keydown` events and `preventDefault()`: buttons don't need a keydown event and when they have a `type="button"` attribute there's no default action to prevent

Props Cheffheid, afercia.

Fixes #31487.

git-svn-id: https://develop.svn.wordpress.org/trunk@37230 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 15:40:50 +00:00
Andrea Fercia
b3b7f6cbac Customizer, Site Icon preview: improve alt attributes and text accessibility.
Props shahpranaf, TacoVerdo, afercia.

Fixes #36562.

git-svn-id: https://develop.svn.wordpress.org/trunk@37229 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 12:00:23 +00:00
Pascal Birchler
ce1a40a07e TinyMCE, inline link: Fix VoiceOver in Safari for search suggestions.
Props afercia.
Fixes #36458.

git-svn-id: https://develop.svn.wordpress.org/trunk@37228 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 11:08:17 +00:00
Pascal Birchler
3d26146c17 Admin: Fix default avatar handling in Settings -> Discussion.
By passing the `force_default` argument to `get_avatar()` instead of using `preg_replace`, we make it easier for developers to override the output.

Props henry.wright.
Fixes #34744.

git-svn-id: https://develop.svn.wordpress.org/trunk@37227 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 10:18:39 +00:00
Jeremy Felt
0f568497a0 Multisite: Make $current_site and $current_blog explicitly global.
See #34941.


git-svn-id: https://develop.svn.wordpress.org/trunk@37226 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 05:11:05 +00:00
Boone Gorges
8ee26e699f Query: Allow results to be ordered by post_parent__in.
Props postpostmodern.
Fixes #36515.

git-svn-id: https://develop.svn.wordpress.org/trunk@37225 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 03:16:36 +00:00
Boone Gorges
d73ec171c0 Tests: Improvements to /post/query test class.
* Add `@group` annotation.
* Remove unnecessary `setUp()` method.

git-svn-id: https://develop.svn.wordpress.org/trunk@37224 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-17 03:12:39 +00:00
Jeremy Felt
426f5256fb Options: Do not set network options to autoload in single site
When multisite is not configured, the `_site_transient()` and `_site_option()` functions fallback to `_option()` and store network "meta/options" in `wp_options`.

Previously, those calls to `_option()` did not explicitly set the `autoload` parameter and anything assigned as a transient or option at the network level would be set to `autoload` by default, even though autoload is not yet a concept at the network option level.

This changes that behavior and forces the `autoload` setting to `no`. If `autoload` is desired, the single site option functions should be used.

Props thomaswm.
Fixes #22846.


git-svn-id: https://develop.svn.wordpress.org/trunk@37223 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 19:47:14 +00:00
Jeremy Felt
83d80f7329 Tests: Run network option tests as single and multisite
The `_network_option()` functions are available to all and
internally use `_option()` functions as a fallback. We should
be testing for that scenario as well.

Fixes #36552.


git-svn-id: https://develop.svn.wordpress.org/trunk@37222 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 19:21:49 +00:00
Andrea Fercia
e4b26366e4 Plugin Install: show the upload form in place rather than sending users to the devoted upload plugin page.
Props Ipstenu, ericlewis, michaelarestad.

Fixes #35429.

git-svn-id: https://develop.svn.wordpress.org/trunk@37221 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 16:42:48 +00:00
Boone Gorges
745018d81a In sanitize_post_field(), only run 'attribute' or 'js' escaping when necessary.
Props tfrommen.
Fixes #34900.

git-svn-id: https://develop.svn.wordpress.org/trunk@37220 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 14:51:01 +00:00
Sergey Biryukov
021fd49054 Themes: Account for longer strings in Theme Details bar on Themes screen.
Fixes #27939.

git-svn-id: https://develop.svn.wordpress.org/trunk@37219 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 13:58:39 +00:00
Sergey Biryukov
a45fb4c863 Plugins: Properly wrap long tab names to a second line in plugin details modal.
Fixes #33221.

git-svn-id: https://develop.svn.wordpress.org/trunk@37218 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 13:17:36 +00:00
Sergey Biryukov
25f590a423 Theme Editor: Add embed.php to file descriptions.
Props ramiy.
Fixes #36551.

git-svn-id: https://develop.svn.wordpress.org/trunk@37217 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 12:46:26 +00:00
Sergey Biryukov
4669eb2706 Docs: Fix typo in wp_cache_switch_to_blog() and WP_Object_Cache::switch_to_blog() description.
Props bobbingwide.
Fixes #36548.

git-svn-id: https://develop.svn.wordpress.org/trunk@37216 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-16 12:36:56 +00:00
Rachel Baker
d0ce9b88fa Comments: Add parameters to edit_comment_link() to allow specifying a Comment and link class.
Matches the parameters for `edit_post_link()`.

Fixes #36538.

Props flixos90.

git-svn-id: https://develop.svn.wordpress.org/trunk@37215 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 20:58:24 +00:00
Sergey Biryukov
b0ed40cb3b Docs: Correct description for override_load_textdomain and override_unload_textdomain filters.
Props dimadin.
Fixes #36537.

git-svn-id: https://develop.svn.wordpress.org/trunk@37214 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 17:18:41 +00:00
Drew Jaynes
29325967e1 Docs: Use third-person singular verbs in DocBlock and hook doc summaries in wp-includes/link-template.php.
See #30406.


git-svn-id: https://develop.svn.wordpress.org/trunk@37213 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 16:57:15 +00:00
Aaron Jorbin
9d68dce5b2 Update grunt-contrib-uglify from ~0.10.0 to ~1.0.1
This changes every JS file in WordPress, so we need to test everything.

Props netweb.
See #36520.


git-svn-id: https://develop.svn.wordpress.org/trunk@37212 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 16:09:07 +00:00
Ella Iseulde Van Dorpe
f261cb7914 Build/Test Tools: Run image tasks only if there are changes
See #36528.


git-svn-id: https://develop.svn.wordpress.org/trunk@37211 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 10:18:03 +00:00
John Blackbourn
6fe6d25f01 Add noindexing to the default wp_die() handler to avoid unnecessary crawl errors in web search engines.
Fixes #34401
Props rodrigosprimo


git-svn-id: https://develop.svn.wordpress.org/trunk@37210 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 02:04:54 +00:00
John Blackbourn
f2f356acfe Docs: Clarify possible types passed to the themes_api_result filter.
See #32246


git-svn-id: https://develop.svn.wordpress.org/trunk@37209 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-15 01:42:11 +00:00
Sergey Biryukov
b24e181d17 Comments: Allow for default comment form action, /wp-comments-post.php, to be changed via the comment_form_defaults filter.
Props cliffseal.
Fixes #26841.

git-svn-id: https://develop.svn.wordpress.org/trunk@37208 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 18:17:23 +00:00
Sergey Biryukov
75fe71a13f Bootstrap/Load: Allow for ABSPATH to be defined outside of wp-load.php, e.g. in a script loaded via auto_prepend_file.
Props barry.
Fixes #26592.

git-svn-id: https://develop.svn.wordpress.org/trunk@37207 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 17:52:02 +00:00
Sergey Biryukov
1694407e0d Build Tools: Don't run the build task twice in grunt prerelease (it already runs via the precommit:js task).
Props netweb.
Fixes #36489.

git-svn-id: https://develop.svn.wordpress.org/trunk@37206 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 15:38:40 +00:00
Konstantin Obenland
6e15892673 Themes: Fix single theme modal on collapsed menu.
Prevents the modal from being displayed off screen, when there is only one
theme available and the menu is collapsed.

Props hardeepasrani for initial patch.
Fixes #36504.



git-svn-id: https://develop.svn.wordpress.org/trunk@37205 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 12:19:47 +00:00
Jeremy Felt
ac48e52ab3 Multisite: Fire a clean_site_cache action when a site's cache is cleared
Props spacedmonkey.
Fixes #36203.


git-svn-id: https://develop.svn.wordpress.org/trunk@37204 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 04:18:54 +00:00
Jeremy Felt
137d716ebb Multisite: Remove theme from network allowed themes when deleted
Previously, a deleted theme would remain in the list of allowed themes until manually cleared. This uses `WP_Theme::network_disable_theme()`, added in [37202].

Fixes #34182.


git-svn-id: https://develop.svn.wordpress.org/trunk@37203 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 03:49:01 +00:00
Jeremy Felt
a56fc1fba0 Multisite: Introduce WP_Theme methods to network enable/disable themes.
* `WP_Theme::network_enable_theme()` can be used to enable a theme or array of themes on a network.
* `WP_Theme::network_disable_theme()` can be used to disable a theme or array of themes on a network.
* Use these new methods in the network admin vs direct `update_site_option()` calls.
* Add tests.

Props igmoweb.
Fixes #30594.


git-svn-id: https://develop.svn.wordpress.org/trunk@37202 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 03:39:45 +00:00
Sergey Biryukov
2fb6a75885 I18N: Add translator comment for a string with a placeholder added in [36806].
Keep the comment for the string above too, for additional clarity.

Props christophherr.
Fixes #36493.

git-svn-id: https://develop.svn.wordpress.org/trunk@37201 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 03:38:09 +00:00
Jeremy Felt
85a6518c57 Multisite: Relocate revoke_super_admin() and grant_super_admin()
Moving these functions to `wp-includes/capabilities.php` allows plugins to access more than just `is_super_admin()` and `get_super_admin()` from the front end without including a file via `wp-admin/`. Add an `is_multisite()` check to prevent use of these on single site environments now that they have left `ms.php`..

Props johnjamesjacoby.
Fixes #21788.


git-svn-id: https://develop.svn.wordpress.org/trunk@37200 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 03:34:07 +00:00
Sergey Biryukov
c39ba1cdd9 Docs: Reference the correct variable in WP_Ajax_UnitTestCase::_handleAjax() documentation.
Props meitar.
Fixes #36522.

git-svn-id: https://develop.svn.wordpress.org/trunk@37199 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 02:28:03 +00:00
Sergey Biryukov
2e6c1d4d6c I18N: Remove <kbd> tags from translatable string in wp-admin/options-writing.php.
Add translator comment.

Props ramiy.
Fixes #36249.

git-svn-id: https://develop.svn.wordpress.org/trunk@37198 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 02:24:49 +00:00
Sergey Biryukov
fc709f0024 Customizer: Remove the 'appearance' reference from permission error messages added in [33857], [33889], and [33902].
Props Frozzare.
Fixes #36466.

git-svn-id: https://develop.svn.wordpress.org/trunk@37197 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-14 01:57:31 +00:00
Boone Gorges
dbf17abf5c Pass thumbnail ID to the admin_post_thumbnail_html filter.
Also updates changelog to reflect that `$post->ID` was added in 3.5

Props johnjamesjacoby.
Fixes #36443.

git-svn-id: https://develop.svn.wordpress.org/trunk@37196 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-13 16:17:10 +00:00
Sergey Biryukov
784c7d75ec Docs: Fix typo in a comment in wp-admin/js/postbox.js.
Props yoavf.
Fixes #36349.

git-svn-id: https://develop.svn.wordpress.org/trunk@37195 602fd350-edb4-49c9-b593-d223f7449a82
2016-04-13 07:28:52 +00:00