Docs: Update the default scheme for get_rest_url() from 'json' to 'rest'.

Also adds 'rest' to the documented list of schemes for `home_url()`, `get_home_url()`, `set_url_scheme()`, and the `home_url` and `set_url_scheme` hooks.

Props rachelbaker.
Fixes #34300.


git-svn-id: https://develop.svn.wordpress.org/trunk@35274 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Drew Jaynes
2015-10-19 22:38:03 +00:00
parent 3ee61161c6
commit 85af87a19b
2 changed files with 17 additions and 14 deletions
+2 -2
View File
@@ -235,10 +235,10 @@ function rest_get_url_prefix() {
*
* @param int $blog_id Optional. Blog ID. Default of null returns URL for current blog.
* @param string $path Optional. REST route. Default '/'.
* @param string $scheme Optional. Sanitization scheme. Default 'json'.
* @param string $scheme Optional. Sanitization scheme. Default 'rest'.
* @return string Full URL to the endpoint.
*/
function get_rest_url( $blog_id = null, $path = '/', $scheme = 'json' ) {
function get_rest_url( $blog_id = null, $path = '/', $scheme = 'rest' ) {
if ( empty( $path ) ) {
$path = '/';
}