Commit Graph

27756 Commits

Author SHA1 Message Date
Mark Jaquith
037e00fb15 Fix weird HiDPI screen rendering issue with theme install preview toolbar
fixes #28898
props ocean90

git-svn-id: https://develop.svn.wordpress.org/trunk@30101 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 22:35:27 +00:00
Dominik Schilling (ocean90)
15af3fdaa8 Improve body class for page templates.
* Convert slash to dash too.
* Add sub-folder name as a separate body class.
* New classes are additional classes, old syntax will persists for BC.

With this `/page-templates/full-width.php` will produce `page-template`, `page-template-page-templates`, `page-template-full-width` and `page-template-page-templatesfull-width-php`.

props obenland, Caspie, donutz.
fixes #23470.

git-svn-id: https://develop.svn.wordpress.org/trunk@30100 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 22:19:08 +00:00
Ian Stewart
f6544f237a Twenty Fifteen: avoid errors by preventing Twenty Fifteen from being activated in old versions of WordPress
Props iamtakashi, fixes #30137.



git-svn-id: https://develop.svn.wordpress.org/trunk@30099 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 22:13:14 +00:00
Boone Gorges
f9e32aef2d Use WP_Comment_Query to query comments in get_approved_comments().
Props dancameron.
See #12668.

git-svn-id: https://develop.svn.wordpress.org/trunk@30098 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 21:57:07 +00:00
Ian Stewart
192e1aac62 Twenty Fifteen: leading the way with support for title-tag
Props obenland, fixes #30146.



git-svn-id: https://develop.svn.wordpress.org/trunk@30097 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 21:55:24 +00:00
Boone Gorges
bd795a3d16 Better flexibility for 'type' in WP_Comment_Query.
* Add support for an array of values in 'type'.
* Introduce `type__in` parameter. This duplicates 'type' but is added for better consistency with other query classes.
* Introduce `type__not_in`.

Among other things, these changes will make it easier for plugin authors to
manage the appearance of custom comment types in various WP interfaces.

Props dancameron, mordauk.
See #12668.

git-svn-id: https://develop.svn.wordpress.org/trunk@30096 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 21:49:08 +00:00
John Blackbourn
6fcb1bf817 Add a hidden submit button to the Appearance -> Header screen so keyboard users can submit the form correctly when a default image provided by the theme is in use.
Fixes #20880.
Props kovshenin, joedolson.


git-svn-id: https://develop.svn.wordpress.org/trunk@30095 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 21:40:58 +00:00
Konstantin Kovshenin
6debe759a6 Use a nested meta query when querying by role in WP_User_Query.
If a user query includes a meta query together with a role argument,
nest the original meta query and append the role meta query with an
AND relationship.

fixes #23849, #27026.


git-svn-id: https://develop.svn.wordpress.org/trunk@30094 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 21:40:04 +00:00
Boone Gorges
555d7347f9 Support an empty string passed as a status in WP_Comment_Query.
The changes in [30084] broke backward compatibility with interfaces that
manually passed an empty string for the value of 'status', such as on
wp-admin/edit-comments.php.

Fixes #29612.

git-svn-id: https://develop.svn.wordpress.org/trunk@30093 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 19:50:31 +00:00
Peter Westwood
ed19e5a1f3 Comment Template Tags: Improve the availability of context information in comment template tag filters.
Fixes #22380 props momo360modena, tareq1988.


git-svn-id: https://develop.svn.wordpress.org/trunk@30092 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 19:07:00 +00:00
John Blackbourn
32d38fc080 Introduce some actions and filters which aid plugins in revisioning post meta.
* `wp_save_post_revision_post_has_changed` filter which can be used to determine if a post has been changed, and therefore if a revision should be created for a post.
 * `wp_get_revision_ui_diff` filter which can be used to filter the fields displayed in the post revision diff UI.
 * `wp_creating_autosave` action which is fired just before an autosave is created.

See #20564.
Props mattheu, adamsilverstein.


git-svn-id: https://develop.svn.wordpress.org/trunk@30091 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 19:01:15 +00:00
John Blackbourn
1767706fc2 Revert [28610] in order to avoid infinite redirect loops on reverse proxies which proxy from HTTPS to HTTP. This will be revisited at some point, possibly as an option via a filter.
Fixes #28610.


git-svn-id: https://develop.svn.wordpress.org/trunk@30090 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 18:36:41 +00:00
Mark Jaquith
7f0f887357 Increase both mystery and humanism
git-svn-id: https://develop.svn.wordpress.org/trunk@30089 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 03:19:45 +00:00
Boone Gorges
c3a3fc5a79 Introduce 'pre_delete_term' hook.
Props cmmarslender.
Fixes #30127.

git-svn-id: https://develop.svn.wordpress.org/trunk@30088 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 02:43:33 +00:00
John Blackbourn
d62320bff5 Correct some logic to populate the defaultValue variable when data.defaultValue begins with a hash symbol.
Props antpb
Fixes #30125


git-svn-id: https://develop.svn.wordpress.org/trunk@30087 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 02:42:35 +00:00
Boone Gorges
e36f06a87f Be more specific in documentation of 'slug' param for get_terms().
Props jfarthing84.
Fixes #23636.

git-svn-id: https://develop.svn.wordpress.org/trunk@30086 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 02:34:56 +00:00
Boone Gorges
114c1f32ba Improve global variable setting in setup_postdata().
`setup_postdata()` is responsible for setting a number of global variables
that are used for post pagination (`$pages`, `$page`, `$nextpage`) and the
generation of post excerpts (`$more`). These variables should be sensitive to
the currently running instance of `WP_Query` - rather than the main query -
so that these features work properly inside of secondary `WP_Query` loops.

This changeset moves the logic of `setup_postdata()` into a method on `WP_Query`,
and converts `setup_postdata()` to a wrapper.

Props boonebgorges, wonderboymusic.
See #25349.
Fixes #9256, #20904.

git-svn-id: https://develop.svn.wordpress.org/trunk@30085 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 02:31:37 +00:00
Boone Gorges
7c4aada4a6 Support multiple 'status' values in WP_Comment_Query.
This change required turning the SQL concatenation into the generation of an
array, for greater flexibility.

Props karpstrucking, ebinnion.
Fixes #29612.

git-svn-id: https://develop.svn.wordpress.org/trunk@30084 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 02:21:10 +00:00
Scott Taylor
5569f01459 Allow developers to override the settings.success callback for MediaElement players.
Props nofearinc.
Fixes #30029.


git-svn-id: https://develop.svn.wordpress.org/trunk@30083 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 01:20:03 +00:00
Scott Taylor
e6bbbb3db9 Don't hardcode height for videos - this was a workaround for MediaElement internals causing problems. Responsive videos now work properly and don't cause extra whitespace.
Fixes MediaElement by hand in the interim: https://github.com/johndyer/mediaelement/pull/1337
Video playlists were completely broken by this.

Fixes #30078.



git-svn-id: https://develop.svn.wordpress.org/trunk@30082 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-29 00:46:15 +00:00
Lance Willett
acbf0229cf Twenty Fifteen: only escape HTML attribute output with esc_attr(). See #30133, props ocean90.
git-svn-id: https://develop.svn.wordpress.org/trunk@30081 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 23:07:32 +00:00
Boone Gorges
66e02d639e Remove call to wp_get_last_changed() from unit tests.
This function was removed in [30073].

See #21760.

git-svn-id: https://develop.svn.wordpress.org/trunk@30080 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 22:02:59 +00:00
Aaron Jorbin
233946b852 Update images based on grunt imagemin
The new version of imagemin that was added in r30059 condenses some images more.

see #30141



git-svn-id: https://develop.svn.wordpress.org/trunk@30079 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 22:01:12 +00:00
Mark Jaquith
42456d35fd Docs and code standards cleanup for [30055] (wp_json_encode() & friends)
fixes #28786
props TobiasBg

git-svn-id: https://develop.svn.wordpress.org/trunk@30078 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:28:34 +00:00
Boone Gorges
0cbc8098d2 Update inline docs for [30052].
Fixes #23261.

git-svn-id: https://develop.svn.wordpress.org/trunk@30077 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:25:30 +00:00
Scott Taylor
45a635d8c2 In _wp_handle_upload(), if test_upload is set to false in the array of dangerous overrides that the function allows, the only thing that happens when an upload fails is more potential breakage.
`$test_uploaded_file` lets is know if `$file['tmp_name']` exists, which allows to exit with an error, instead of continuing to attempt to move the file.

`$test_upload` override is now a noop.

Fixes #28208.


git-svn-id: https://develop.svn.wordpress.org/trunk@30076 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:16:06 +00:00
Mark Jaquith
52151956ea Define JSON_PRETTY_PRINT so it can be used with wp_json_encode()
* `JSON_PRETTY_PRINT` was introduced in PHP 5.4
* Now you can use it with lower PHP versions, without a notice

fixes #30139
see #28786

git-svn-id: https://develop.svn.wordpress.org/trunk@30075 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:12:10 +00:00
John Blackbourn
efb9cd0cc5 Introduce a new means of outputting a <title> tag in the theme head. Requires a theme to add support by calling add_theme_support( 'title-tag' ). This is the first step in adding a more robust means of generating and outputting the title tag.
See #18548.
Props obenland, chrisbliss18, joostdevalk.



git-svn-id: https://develop.svn.wordpress.org/trunk@30074 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:11:11 +00:00
Scott Taylor
1e8635fcea Adjust caching for get_term_by() calls:
* Remove md5 hashes for term name cache keys
* Remove the namespace for the keys for `names` and `slugs` and add them to the group names
* Remove `wp_get_last_changed()`, which @nacin hated
 
Props tollmanz.
Fixes #21760.


git-svn-id: https://develop.svn.wordpress.org/trunk@30073 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:04:52 +00:00
iandstewart
e5275dcedb Twenty Fifteen: Use a heading heirarchy to provide a better navigation experience when using screenreading software.
Props davidakennedy, rianrietveld, iamtakashi, afercia, davidakennedy, fixes #30065.


git-svn-id: https://develop.svn.wordpress.org/trunk@30072 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 21:02:02 +00:00
Jeremy Felt
d80d1c2ffe Introduce wp_is_trusted_network()
A first step to establish concepts around trusted and untrusted networks.

* Will always return false as default.
* Will one day have a filter.

Fixes #30145


git-svn-id: https://develop.svn.wordpress.org/trunk@30071 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 20:55:39 +00:00
Aaron Jorbin
7ca2e674cd Autoprefix box sizing
Results are from running grunt autoprefix.  Needed for FF before 29 and Safari before 5.1.

fixes #27553



git-svn-id: https://develop.svn.wordpress.org/trunk@30070 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 20:47:30 +00:00
Aaron Jorbin
c9dfc6bebb Don't cascade autoprefixer output
Autoprefixer changed the default for cascade from false to true. Our css coding standards do not include the cascade for browser prefixes.
Introduced in r30067

see #30141



git-svn-id: https://develop.svn.wordpress.org/trunk@30069 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 20:44:33 +00:00
Scott Taylor
74ed2089b4 The gallery shortcode used to accept a SQL chunk for the value of the orderby attribute. The reason? get_posts() used to be called in the shortcode handler with a query-string blob of arguments passed to it. To mitigate breakage, sanitize_sql_orderby() was created in [7592].
`sanitize_sql_orderby()` expects a comma to be present when multiple `orderby` values were passed. The correct syntax for multiple fields is space-delimited. Since [29027], comma-separated values would never be parsed correctly when passed to `WP_Query->parse_orderby()`.

`sanitize_sql_orderby()` is used nowhere else in core, save for the `playlist` shortcode - I only added it there because I was mimic'ing the `gallery` logic. The function call can be removed from both shortcode handlers.
 
See #6476.
Fixes #23873.


git-svn-id: https://develop.svn.wordpress.org/trunk@30068 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 20:42:20 +00:00
Aaron Jorbin
489da6a815 Update grunt-autoprefixer to 1.0.1
Upstream changes https://github.com/nDmitry/grunt-autoprefixer/compare/v0.8.2...v1.0.1

see #30141


git-svn-id: https://develop.svn.wordpress.org/trunk@30067 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 20:16:32 +00:00
Aaron Jorbin
d6f0d2c273 Update grunt-contrib-uglify to 0.6.0
Upstream changes https://github.com/gruntjs/grunt-contrib-uglify/compare/v0.5.0...v0.6.0

see #30141


git-svn-id: https://develop.svn.wordpress.org/trunk@30066 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:49:26 +00:00
John Blackbourn
f08525846a Introduce some new template functions for navigation:
* `get_the_post_navigation()` and `the_post_navigation()` for navigation to the next and previous post.
 * `get_the_posts_navigation() and `the_posts_navigation()` for navigation to the next and previous page of posts.
 * `get_the_pagination()` and `the_pagination()` for paginated navigation between pages of posts. Uses `paginate_links()`.

This reduces the need for themes to define their own sets of navigation functions.

Fixes #29808.
Props obenland.
 


git-svn-id: https://develop.svn.wordpress.org/trunk@30065 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:38:41 +00:00
Scott Taylor
159423cef9 Add audio, video, and track to $allowedposttags (KSES).
Props jwenerd, wonderboymusic. 
Fixes #29826.


git-svn-id: https://develop.svn.wordpress.org/trunk@30064 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:35:17 +00:00
Aaron Jorbin
2285c9195d Update grunt-contrib-copy to 0.7.0
Upstream changes https://github.com/gruntjs/grunt-contrib-copy/compare/v0.5.0...v0.7.0

see #30141


git-svn-id: https://develop.svn.wordpress.org/trunk@30063 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:34:41 +00:00
Aaron Jorbin
e186ad870c Update grunt-contrib-clean to 0.6.0
Upstream changes https://github.com/gruntjs/grunt-contrib-clean/compare/v0.5.0...v0.6.0

see #30141


git-svn-id: https://develop.svn.wordpress.org/trunk@30062 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:30:24 +00:00
Aaron Jorbin
7a9792234a Update grunt-sass to 0.16.0
Upstream changes https://github.com/sindresorhus/grunt-sass/compare/v0.14.0...v0.16.0

see #30141



git-svn-id: https://develop.svn.wordpress.org/trunk@30061 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:26:21 +00:00
Aaron Jorbin
bbdab64ed3 Update grunt-contrib-compress to 0.12.0
Upstream changes f0762ba6e2...v0.12.0

see #30141



git-svn-id: https://develop.svn.wordpress.org/trunk@30060 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:20:48 +00:00
Aaron Jorbin
6212d0607d Update grunt-contrib-imagemin to 0.9.1
Upstream changes https://github.com/gruntjs/grunt-contrib-imagemin/compare/v0.4.1...v0.9.1

see #30141



git-svn-id: https://develop.svn.wordpress.org/trunk@30059 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 19:11:37 +00:00
Gary Pendergast
d871bf86ca Fix a PHPDoc typo for wp_json_encode().
Props JustinSainton.

See #28786.


git-svn-id: https://develop.svn.wordpress.org/trunk@30058 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:53:10 +00:00
Peter Westwood
bc779f1915 Update the root svn:ignore property to match .gitignores. Fixes #30134.
git-svn-id: https://develop.svn.wordpress.org/trunk@30057 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:44:34 +00:00
Boone Gorges
ad4aa0b7e0 Remove UNIQUE key from 'slug' column of terms table.
Each slug is a unique and beautiful snowflake, but let's enforce that
uniqueness elsewhere.

Props hotchkissconsulting.
Fixes #22023.

git-svn-id: https://develop.svn.wordpress.org/trunk@30056 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:36:57 +00:00
Gary Pendergast
0e68ecc0b6 Add wp_json_encode(), a wrapper for json_encode() that ensures everything is converted to UTF-8.
Change all core calls from `json_encode()` to `wp_json_encode()`.

Fixes #28786.



git-svn-id: https://develop.svn.wordpress.org/trunk@30055 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:34:16 +00:00
John Blackbourn
3d35d8bc5d Add a missing Oxford comma to the install screen. Fixes #30107. Props Ankit K Gupta.
git-svn-id: https://develop.svn.wordpress.org/trunk@30054 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:31:19 +00:00
John Blackbourn
105b60bd0b Make the Twenty Fifteen search form submit button screen reader accessible rather than hidden to all users. Fixes #30110. Props mattweibe, rianrietveld.
git-svn-id: https://develop.svn.wordpress.org/trunk@30053 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:13:19 +00:00
Boone Gorges
6df24465f4 Introduce orderby=include support for get_terms().
Props wpsmith.
Fixes #23261.

git-svn-id: https://develop.svn.wordpress.org/trunk@30052 602fd350-edb4-49c9-b593-d223f7449a82
2014-10-28 18:12:30 +00:00