Allow `get_comments_number()` to officially accept `$post` or `$post_id`. Adds unit tests.

Props coffee2code, JanHenkG.
Fixes #26240.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28384 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Read the `src` attribute for the `[embed]` shortcode if the shortcode's body is empty.

These work:
`[embed src="https://www.youtube.com/watch?v=ZqD-LPOWIT0"]`
`[embed src="https://www.youtube.com/watch?v=ZqD-LPOWIT0"][/embed]`

If you do:
`[embed src="https://www.youtube.com/watch?v=ZqD-LPOWIT0"]http://any-other-url.com[/embed]`

... "http://any-other-url.com" will be the URL that is parsed.

Props kovshenin, aaroncampbell for making initial patches.
Fixes #24456.


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


git-svn-id: http://core.svn.wordpress.org/trunk@28385 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Truly check for `! empty()` instead of falsey `''` when determining whether to add `LIMIT` clause to SQL in `wp_get_archives()`.

Props jjeaton for the initial patch.
Fixes #27834.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28386 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In `get_terms_to_edit()`, call `get_object_term_cache()` before priming cache with `wp_get_object_terms()`.

In `get_inline_data()`, do the same.

On list table screens with taxonomies in the admin, this dramatically reduces the number of database queries (3x less). Even more so with a persistent object cache (5x less).

Props johnbillion, jeffstieler, wonderboymusic.
Fixes #18968.


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


git-svn-id: http://core.svn.wordpress.org/trunk@28387 1a063a9b-81f0-0310-95a4-ce76da25c4cd
When adding queries to `tax_query`: if the query's `field` is `term_taxonomy_id`, don't require `taxonomy` to be specified. In `WP_Tax_Query::transform_query()`, `$query['taxonomy']` is never checked for the 'term_taxonomy_id' `case` because 'term_taxonomy_id' is the primary key being looked up.

Adds unit tests.

Props helen.
Fixes #25284.


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


git-svn-id: http://core.svn.wordpress.org/trunk@28388 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Replaces all uses of `TEMPLATEPATH` and `STYLESHEETPATH` in core with `get_template_directory()` and `get_stylesheet_directory()`.

Add `@deprecated` annotations to `TEMPLATEPATH` and `STYLESHEETPATH` definitions.

Props obenland, aaroncampbell. 
Fixes #18298.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28389 1a063a9b-81f0-0310-95a4-ce76da25c4cd
`wp_dropdown_pages()` allows `option_none_value` to be passed. Add that arg to the `$defaults` for `wp_dropdown_users()` and `wp_dropdown_categories()` as well.

Props solarissmoke. 
Fixes #16625.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28390 1a063a9b-81f0-0310-95a4-ce76da25c4cd
wpView: fix selecting a view's text string in Safari, props gcorne, fixes #28088
Built from https://develop.svn.wordpress.org/trunk@28565


git-svn-id: http://core.svn.wordpress.org/trunk@28391 1a063a9b-81f0-0310-95a4-ce76da25c4cd
In `media_sideload_image()`, check the returned value of `download_url()` earlier to avoid attempting to `unlink()` an instance of `WP_Error`.

Props georgestephanis. 
Fixes #28204.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28392 1a063a9b-81f0-0310-95a4-ce76da25c4cd
TinyMCE: update to 4.0.26. Includes fixes for the 'paste' plugin (paste from Word/Excel, paste in WebKit/Blink), show/hide/isHidden in inline mode, drag/drop in tables and in Safari, and others. Fixes #28342, #28016, #28250 and #28067
Built from https://develop.svn.wordpress.org/trunk@28568


git-svn-id: http://core.svn.wordpress.org/trunk@28393 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Use three-digit x.x.x style version for `@deprecated` phpDoc tags.

See #18298.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28394 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Add inline documentation for the `option_none_value` argument added to `wp_dropdown_users|categories()` in [28564].

Fixes #16625.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28395 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Pass $post to 'protected_title_format' and 'private_title_format' filters.

props johnjamesjacoby, DrewAPicture.
fixes #23724.
Built from https://develop.svn.wordpress.org/trunk@28571


git-svn-id: http://core.svn.wordpress.org/trunk@28396 1a063a9b-81f0-0310-95a4-ce76da25c4cd