Make WordPress Core

Changeset 36386


Ignore:
Timestamp:
01/23/2016 04:46:31 PM (9 years ago)
Author:
ericlewis
Message:

Networks and sites: Replace "blog" usage with "site" in docs.

This effort focuses on src/wp-includes/link-template.php.

Multisite functions use the term "blog" to refer to what we now call a "site," e.g. get_current_blog_id(). These functions are here to stay because of our commitment to backwards compatibility. What we can do is set the documentation straight.

Props mrahmadawais.
Fixes #35589.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/link-template.php

    r36308 r36386  
    2929
    3030/**
    31  * Retrieve trailing slash string, if blog set for adding trailing slashes.
     31 * Retrieve trailing slash string, if site is set for adding trailing slashes.
    3232 *
    3333 * Conditionally adds a trailing slash if the permalink structure has a trailing
    3434 * slash, strips the trailing slash if not. The string is passed through the
    3535 * 'user_trailingslashit' filter. Will remove trailing slash from string, if
    36  * blog is not set to have them.
     36 * site is not set to have them.
    3737 *
    3838 * @since 2.2.0
     
    14331433
    14341434/**
    1435  * Display edit bookmark (literally a URL external to blog) link.
     1435 * Display edit bookmark link.
    14361436 *
    14371437 * @since 2.7.0
     
    14491449
    14501450    /**
    1451      * Filter the bookmark (link) edit link.
     1451     * Filter the bookmark edit link.
    14521452     *
    14531453     * @since 2.7.0
     
    14601460
    14611461/**
    1462  * Display edit bookmark (literally a URL external to blog) link anchor content.
     1462 * Display edit bookmark link anchor content.
    14631463 *
    14641464 * @since 2.7.0
     
    29552955 * @global string $pagenow
    29562956 *
    2957  * @param  int         $blog_id Optional. Blog ID. Default null (current blog).
     2957 * @param  int         $blog_id Optional. Site ID. Default null (current site).
    29582958 * @param  string      $path    Optional. Path relative to the home URL. Default empty.
    29592959 * @param  string|null $scheme  Optional. Scheme to give the home URL context. Accepts
     
    29952995     * @param string|null $orig_scheme Scheme to give the home URL context. Accepts 'http', 'https',
    29962996     *                                 'relative', 'rest', or null.
    2997      * @param int|null    $blog_id     Blog ID, or null for the current blog.
     2997     * @param int|null    $blog_id     Site ID, or null for the current site.
    29982998     */
    29992999    return apply_filters( 'home_url', $url, $path, $orig_scheme, $blog_id );
     
    30263026 * @since 3.0.0
    30273027 *
    3028  * @param int    $blog_id Optional. Blog ID. Default null (current site).
     3028 * @param int    $blog_id Optional. Site ID. Default null (current site).
    30293029 * @param string $path    Optional. Path relative to the site url. Default empty.
    30303030 * @param string $scheme  Optional. Scheme to give the site url context. Accepts
     
    30563056     * @param string|null $scheme  Scheme to give the site URL context. Accepts 'http', 'https', 'login',
    30573057     *                             'login_post', 'admin', 'relative' or null.
    3058      * @param int|null    $blog_id Blog ID, or null for the current blog.
     3058     * @param int|null    $blog_id Site ID, or null for the current site.
    30593059     */
    30603060    return apply_filters( 'site_url', $url, $path, $scheme, $blog_id );
     
    30793079 * @since 3.0.0
    30803080 *
    3081  * @param int    $blog_id Optional. Blog ID. Default null (current site).
     3081 * @param int    $blog_id Optional. Site ID. Default null (current site).
    30823082 * @param string $path    Optional. Path relative to the admin url. Default empty.
    30833083 * @param string $scheme  Optional. The scheme to use. Accepts 'http' or 'https',
     
    30993099     * @param string   $url     The complete admin area URL including scheme and path.
    31003100     * @param string   $path    Path relative to the admin area URL. Blank string if no path is specified.
    3101      * @param int|null $blog_id Blog ID, or null for the current blog.
     3101     * @param int|null $blog_id Site ID, or null for the current site.
    31023102     */
    31033103    return apply_filters( 'admin_url', $url, $path, $blog_id );
     
    33533353
    33543354/**
    3355  * Retrieve the url to the admin area for either the current blog or the network depending on context.
     3355 * Retrieve the url to the admin area for either the current site or the network depending on context.
    33563356 *
    33573357 * @since 3.1.0
     
    34223422 * If a user does not belong to any site, the global user dashboard is used. If the user belongs to the current site,
    34233423 * the dashboard for the current site is returned. If the user cannot edit the current site, the dashboard to the user's
    3424  * primary blog is returned.
     3424 * primary site is returned.
    34253425 *
    34263426 * @since 3.1.0
    34273427 *
    34283428 * @param int    $user_id Optional. User ID. Defaults to current user.
    3429  * @param string $path    Optional path relative to the dashboard. Use only paths known to both blog and user admins.
     3429 * @param string $path    Optional path relative to the dashboard. Use only paths known to both site and user admins.
    34303430 * @param string $scheme  The scheme to use. Default is 'admin', which obeys force_ssl_admin() and is_ssl(). 'http' or 'https' can be passed to force those schemes.
    34313431 * @return string Dashboard url link with optional path appended.
     
    35323532
    35333533/**
    3534  * Return a shortlink for a post, page, attachment, or blog.
     3534 * Return a shortlink for a post, page, attachment, or a site.
    35353535 *
    35363536 * This function exists to provide a shortlink tag that all themes and plugins can target. A plugin must hook in to
     
    35413541 * @since 3.0.0.
    35423542 *
    3543  * @param int    $id          A post or blog id. Default is 0, which means the current post or blog.
    3544  * @param string $context     Whether the id is a 'blog' id, 'post' id, or 'media' id.
     3543 * @param int    $id          A post or site id. Default is 0, which means the current post or site.
     3544 * @param string $context     Whether the id is a 'site' id, 'post' id, or 'media' id.
    35453545 *                            If 'post', the post_type of the post is consulted.
    35463546 *                            If 'query', the current query is consulted to determine the id and context.
Note: See TracChangeset for help on using the changeset viewer.