Make WordPress Core

Changeset 53060


Ignore:
Timestamp:
04/04/2022 06:24:18 PM (2 years ago)
Author:
SergeyBiryukov
Message:

Docs: Add missing description for $pagenow global in various functions.

See #54729, #55499.

Location:
trunk/src
Files:
22 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/admin-header.php

    r52285 r53060  
    1919 * @global WP_Screen $current_screen     WordPress current screen object.
    2020 * @global WP_Locale $wp_locale          WordPress date and time locale object.
    21  * @global string    $pagenow
     21 * @global string    $pagenow            The filename of the current screen.
    2222 * @global string    $update_title
    2323 * @global int       $total_update_count
  • trunk/src/wp-admin/admin.php

    r51475 r53060  
    117117
    118118/**
    119  * $pagenow is set in vars.php
    120  * $wp_importers is sometimes set in wp-admin/includes/import.php
    121  * The remaining variables are imported as globals elsewhere, declared as globals here
    122  *
    123  * @global string $pagenow
     119 * $pagenow is set in vars.php.
     120 * $wp_importers is sometimes set in wp-admin/includes/import.php.
     121 * The remaining variables are imported as globals elsewhere, declared as globals here.
     122 *
     123 * @global string $pagenow      The filename of the current screen.
    124124 * @global array  $wp_importers
    125125 * @global string $hook_suffix
     
    377377     *
    378378     * The dynamic portion of the hook name, `$pagenow`, is a global variable
    379      * referring to the filename of the current page, such as 'admin.php',
     379     * referring to the filename of the current screen, such as 'admin.php',
    380380     * 'post-new.php' etc. A complete hook for the latter would be
    381381     * 'load-post-new.php'.
  • trunk/src/wp-admin/includes/bookmark.php

    r52659 r53060  
    328328 * @access private
    329329 *
    330  * @global string $pagenow
     330 * @global string $pagenow The filename of the current screen.
    331331 */
    332332function wp_link_manager_disabled_message() {
  • trunk/src/wp-admin/includes/file.php

    r52978 r53060  
    21472147 * @since 4.6.0 The `$context` parameter default changed from `false` to an empty string.
    21482148 *
    2149  * @global string $pagenow
     2149 * @global string $pagenow The filename of the current screen.
    21502150 *
    21512151 * @param string        $form_post                    The URL to post the form to.
  • trunk/src/wp-admin/includes/misc.php

    r52732 r53060  
    12771277 * @since 3.8.0
    12781278 *
    1279  * @global string $pagenow
     1279 * @global string $pagenow The filename of the current screen.
    12801280 *
    12811281 * @param array $settings An array of Heartbeat settings.
  • trunk/src/wp-admin/includes/ms.php

    r52332 r53060  
    693693 *
    694694 * @global int    $wp_db_version WordPress database version.
    695  * @global string $pagenow
     695 * @global string $pagenow       The filename of the current screen.
    696696 *
    697697 * @return void|false Void on success. False if the current user is not a super admin.
     
    10301030 * @since 4.6.0
    10311031 *
    1032  * @global string $pagenow
     1032 * @global string $pagenow The filename of the current screen.
    10331033 *
    10341034 * @param array $args {
  • trunk/src/wp-admin/includes/plugin.php

    r52934 r53060  
    18591859 * @global array  $menu
    18601860 * @global array  $submenu
    1861  * @global string $pagenow
     1861 * @global string $pagenow              The filename of the current screen.
    18621862 * @global string $typenow
    18631863 * @global string $plugin_page
     
    19501950 * @global array $menu
    19511951 * @global array $submenu
    1952  * @global string $pagenow
     1952 * @global string $pagenow     The filename of the current screen.
    19531953 * @global string $plugin_page
    19541954 * @global string $typenow
     
    20852085 * @since 1.5.0
    20862086 *
    2087  * @global string $pagenow
     2087 * @global string $pagenow            The filename of the current screen.
    20882088 * @global array  $menu
    20892089 * @global array  $submenu
     
    24682468 * @since 5.2.0
    24692469 *
    2470  * @global string $pagenow
     2470 * @global string $pagenow The filename of the current screen.
    24712471 */
    24722472function paused_plugins_notice() {
     
    25012501 * @access private
    25022502 *
    2503  * @global string $pagenow
    2504  * @global string $wp_version
     2503 * @global string $pagenow    The filename of the current screen.
     2504 * @global string $wp_version The WordPress version string.
    25052505 */
    25062506function deactivated_plugins_notice() {
  • trunk/src/wp-admin/includes/theme.php

    r53002 r53060  
    11861186 * @since 5.2.0
    11871187 *
    1188  * @global string $pagenow
     1188 * @global string $pagenow The filename of the current screen.
    11891189 */
    11901190function paused_themes_notice() {
  • trunk/src/wp-admin/includes/update-core.php

    r52640 r53060  
    15551555 *
    15561556 * @global string $wp_version The WordPress version string.
    1557  * @global string $pagenow
     1557 * @global string $pagenow    The filename of the current screen.
    15581558 * @global string $action
    15591559 *
  • trunk/src/wp-admin/includes/update.php

    r52978 r53060  
    278278 * @since 2.3.0
    279279 *
    280  * @global string $pagenow
     280 * @global string $pagenow The filename of the current screen.
    281281 * @return void|false
    282282 */
    283283function update_nag() {
     284    global $pagenow;
     285
    284286    if ( is_multisite() && ! current_user_can( 'update_core' ) ) {
    285287        return false;
    286288    }
    287 
    288     global $pagenow;
    289289
    290290    if ( 'update-core.php' === $pagenow ) {
  • trunk/src/wp-admin/includes/user.php

    r52978 r53060  
    511511 * @since 2.8.0
    512512 *
    513  * @global string $pagenow
     513 * @global string $pagenow The filename of the current screen.
    514514 */
    515515function default_password_nag() {
    516516    global $pagenow;
     517
    517518    // Short-circuit it.
    518519    if ( 'profile.php' === $pagenow || ! get_user_option( 'default_password_nag' ) ) {
  • trunk/src/wp-includes/admin-bar.php

    r52414 r53060  
    12341234 *
    12351235 * @global bool   $show_admin_bar
    1236  * @global string $pagenow
     1236 * @global string $pagenow        The filename of the current screen.
    12371237 *
    12381238 * @return bool Whether the admin bar should be showing.
  • trunk/src/wp-includes/class-wp-customize-manager.php

    r53059 r53060  
    501501     * @since 3.4.0
    502502     *
    503      * @global string $pagenow
     503     * @global string $pagenow The filename of the current screen.
    504504     */
    505505    public function setup_theme() {
     
    608608     * @since 4.9.0
    609609     *
    610      * @global string $pagenow
     610     * @global string $pagenow The filename of the current screen.
    611611     */
    612612    public function establish_loaded_changeset() {
     
    32863286     * @since 4.9.0
    32873287     *
    3288      * @global string $pagenow
     3288     * @global string $pagenow The filename of the current screen.
    32893289     *
    32903290     * @param array $settings Current settings to filter.
  • trunk/src/wp-includes/class-wp-recovery-mode-link-service.php

    r50407 r53060  
    6666     * @since 5.2.0
    6767     *
    68      * @global string $pagenow
     68     * @global string $pagenow The filename of the current screen.
    6969     *
    7070     * @param int $ttl Number of seconds the link should be valid for.
  • trunk/src/wp-includes/functions.php

    r53045 r53060  
    84008400 * @since 5.2.0
    84018401 *
    8402  * @global string $wp_version WordPress version.
     8402 * @global string $wp_version The WordPress version string.
    84038403 *
    84048404 * @param string $required Minimum required WordPress version.
  • trunk/src/wp-includes/functions.wp-scripts.php

    r53053 r53060  
    259259 * @since 2.1.0
    260260 *
    261  * @global string $pagenow
     261 * @global string $pagenow The filename of the current screen.
    262262 *
    263263 * @param string $handle Name of the script to be removed.
  • trunk/src/wp-includes/l10n.php

    r52933 r53060  
    115115 * @since 5.0.0
    116116 *
    117  * @global string $pagenow
     117 * @global string $pagenow The filename of the current screen.
    118118 *
    119119 * @return string The determined locale.
  • trunk/src/wp-includes/load.php

    r52398 r53060  
    887887 * @access private
    888888 *
     889 * @global string $pagenow The filename of the current screen.
     890 *
    889891 * @return string[] Array of absolute paths to theme directories.
    890892 */
     
    967969 * @since 5.2.0
    968970 *
    969  * @global string $pagenow
     971 * @global string $pagenow The filename of the current screen.
    970972 *
    971973 * @return bool True if the current endpoint should be protected.
     
    17471749 * @since 5.6.1
    17481750 *
    1749  * @global string $pagenow The current page.
     1751 * @global string $pagenow The filename of the current screen.
    17501752 *
    17511753 * @param string $context The context to check for protection. Accepts 'login', 'admin', and 'front'.
  • trunk/src/wp-includes/post.php

    r53058 r53060  
    65786578 * @since 2.1.0
    65796579 *
    6580  * @global string $pagenow
     6580 * @global string $pagenow The filename of the current screen.
    65816581 *
    65826582 * @param int $attachment_id Optional. Attachment post ID. Defaults to global $post.
  • trunk/src/wp-includes/script-loader.php

    r53025 r53060  
    28482848 *
    28492849 * @since 5.8.0
     2850 *
     2851 * @global string $pagenow The filename of the current screen.
    28502852 */
    28512853function wp_add_iframed_editor_assets_html() {
  • trunk/src/wp-includes/user.php

    r53018 r53060  
    37133713 * @since 4.9.0 This function was moved from wp-admin/includes/ms.php so it's no longer Multisite specific.
    37143714 *
    3715  * @global string $pagenow
     3715 * @global string $pagenow The filename of the current screen.
    37163716 */
    37173717function new_user_email_admin_notice() {
  • trunk/src/wp-includes/vars.php

    r52825 r53060  
    33 * Creates common globals for the rest of WordPress
    44 *
    5  * Sets $pagenow global which is the current page. Checks
    6  * for the browser to set which one is currently being used.
     5 * Sets $pagenow global which is the filename of the current screen.
     6 * Checks for the browser to set which one is currently being used.
    77 *
    88 * Detects which user environment WordPress is being used on.
Note: See TracChangeset for help on using the changeset viewer.