Make WordPress Core

Ticket #53426: 53426-1.2.diff

File 53426-1.2.diff, 11.9 KB (added by chintan1896, 3 years ago)

Refresh patch added

  • wp-admin/about.php

     
    2323
    2424                <div class="about__header">
    2525                        <div class="about__header-image">
    26                                 <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo admin_url( 'images/about-badge.svg' ); ?>" />
     26                                <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo esc_url( admin_url( 'images/about-badge.svg' ) ); ?>" />
    2727                        </div>
    2828
    2929                        <div class="about__header-title">
     
    233233                <div class="about__section has-subtle-background-color">
    234234                        <div class="column about__image">
    235235                                <picture>
    236                                         <source media="(max-width: 600px)" srcset="<?php echo admin_url( 'images/about-color-palette-vert.svg' ); ?>" />
    237                                         <img alt="" src="<?php echo admin_url( 'images/about-color-palette.svg' ); ?>" />
     236                                        <source media="(max-width: 600px)" srcset="<?php echo esc_url( admin_url( 'images/about-color-palette-vert.svg' ) ); ?>" />
     237                                        <img alt="" src="<?php echo esc_url( admin_url( 'images/about-color-palette.svg' ) ); ?>" />
    238238                                </picture>
    239239                        </div>
    240240                </div>
  • wp-admin/comment.php

     
    232232        <th scope="row"><?php /* translators: Field name in comment form. */ _ex( 'Comment', 'noun' ); ?></th>
    233233        <td class="comment-content">
    234234                <?php comment_text( $comment ); ?>
    235         <p class="edit-comment"><a href="<?php echo admin_url( "comment.php?action=editcomment&amp;c={$comment->comment_ID}" ); ?>"><?php esc_html_e( 'Edit' ); ?></a></p>
     235        <p class="edit-comment"><a href="<?php echo esc_url( admin_url( "comment.php?action=editcomment&amp;c={$comment->comment_ID}" ) ); ?>"><?php esc_html_e( 'Edit' ); ?></a></p>
    236236        </td>
    237237        </tr>
    238238        </table>
     
    241241
    242242        <p>
    243243                <?php submit_button( $button, 'primary', 'submit', false ); ?>
    244         <a href="<?php echo admin_url( 'edit-comments.php' ); ?>" class="button-cancel"><?php esc_html_e( 'Cancel' ); ?></a>
     244        <a href="<?php echo esc_url( admin_url( 'edit-comments.php' ) ); ?>" class="button-cancel"><?php esc_html_e( 'Cancel' ); ?></a>
    245245        </p>
    246246
    247247                <?php wp_nonce_field( $nonce_action ); ?>
  • wp-admin/credits.php

     
    2222
    2323        <div class="about__header">
    2424                <div class="about__header-image">
    25                         <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo admin_url( 'images/about-badge.svg' ); ?>" />
     25                        <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo esc_url( admin_url( 'images/about-badge.svg' ) ); ?>" />
    2626                </div>
    2727
    2828                <div class="about__header-container">
  • wp-admin/edit-tag-form.php

     
    275275
    276276        <?php if ( current_user_can( 'delete_term', $tag->term_id ) ) : ?>
    277277                <span id="delete-link">
    278                         <a class="delete" href="<?php echo admin_url( wp_nonce_url( "edit-tags.php?action=delete&taxonomy=$taxonomy&tag_ID=$tag->term_id", 'delete-tag_' . $tag->term_id ) ); ?>"><?php _e( 'Delete' ); ?></a>
     278                        <a class="delete" href="<?php echo esc_url( admin_url( wp_nonce_url( "edit-tags.php?action=delete&taxonomy=$taxonomy&tag_ID=$tag->term_id", 'delete-tag_' . $tag->term_id ) ) ); ?>"><?php _e( 'Delete' ); ?></a>
    279279                </span>
    280280        <?php endif; ?>
    281281
  • wp-admin/freedoms.php

     
    2525
    2626        <div class="about__header">
    2727                <div class="about__header-image">
    28                         <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo admin_url( 'images/about-badge.svg' ); ?>" />
     28                        <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo esc_url( admin_url( 'images/about-badge.svg' ) ); ?>" />
    2929                </div>
    3030
    3131                <div class="about__header-container">
  • wp-admin/includes/dashboard.php

     
    19261926                        <h3><?php _e( 'Get Started' ); ?></h3>
    19271927                        <a class="button button-primary button-hero load-customize hide-if-no-customize" href="<?php echo wp_customize_url(); ?>"><?php _e( 'Customize Your Site' ); ?></a>
    19281928                <?php endif; ?>
    1929                 <a class="button button-primary button-hero hide-if-customize" href="<?php echo admin_url( 'themes.php' ); ?>"><?php _e( 'Customize Your Site' ); ?></a>
     1929                <a class="button button-primary button-hero hide-if-customize" href="<?php echo esc_url( admin_url( 'themes.php' ) ); ?>"><?php _e( 'Customize Your Site' ); ?></a>
    19301930                <?php if ( current_user_can( 'install_themes' ) || ( current_user_can( 'switch_themes' ) && count( wp_get_themes( array( 'allowed' => true ) ) ) > 1 ) ) : ?>
    19311931                        <?php $themes_link = current_user_can( 'customize' ) ? add_query_arg( 'autofocus[panel]', 'themes', admin_url( 'customize.php' ) ) : admin_url( 'themes.php' ); ?>
    19321932                        <p class="hide-if-no-customize">
  • wp-admin/includes/image-edit.php

     
    9090                <input type="hidden" id="imgedit-y-<?php echo $post_id; ?>" value="<?php echo isset( $meta['height'] ) ? $meta['height'] : 0; ?>" />
    9191
    9292                <div id="imgedit-crop-<?php echo $post_id; ?>" class="imgedit-crop-wrap">
    93                 <img id="image-preview-<?php echo $post_id; ?>" onload="imageEdit.imgLoaded('<?php echo $post_id; ?>')" src="<?php echo admin_url( 'admin-ajax.php', 'relative' ); ?>?action=imgedit-preview&amp;_ajax_nonce=<?php echo $nonce; ?>&amp;postid=<?php echo $post_id; ?>&amp;rand=<?php echo rand( 1, 99999 ); ?>" alt="" />
     93                <img id="image-preview-<?php echo $post_id; ?>" onload="imageEdit.imgLoaded('<?php echo $post_id; ?>')" src="<?php echo esc_url( admin_url( 'admin-ajax.php', 'relative' ) ); ?>?action=imgedit-preview&amp;_ajax_nonce=<?php echo $nonce; ?>&amp;postid=<?php echo $post_id; ?>&amp;rand=<?php echo rand( 1, 99999 ); ?>" alt="" />
    9494                </div>
    9595
    9696                <div class="imgedit-submit">
  • wp-admin/media-new.php

     
    7272<div class="wrap">
    7373        <h1><?php echo esc_html( $title ); ?></h1>
    7474
    75         <form enctype="multipart/form-data" method="post" action="<?php echo admin_url( 'media-new.php' ); ?>" class="<?php echo esc_attr( $form_class ); ?>" id="file-form">
     75        <form enctype="multipart/form-data" method="post" action="<?php echo esc_url( admin_url( 'media-new.php' ) ); ?>" class="<?php echo esc_attr( $form_class ); ?>" id="file-form">
    7676
    7777        <?php media_upload_form(); ?>
    7878
  • wp-admin/nav-menus.php

     
    685685        <hr class="wp-header-end">
    686686
    687687        <nav class="nav-tab-wrapper wp-clearfix" aria-label="<?php esc_attr_e( 'Secondary menu' ); ?>">
    688                 <a href="<?php echo admin_url( 'nav-menus.php' ); ?>" class="nav-tab<?php echo $nav_tab_active_class; ?>"<?php echo $nav_aria_current; ?>><?php esc_html_e( 'Edit Menus' ); ?></a>
     688                <a href="<?php echo esc_url( admin_url( 'nav-menus.php' ) ); ?>" class="nav-tab<?php echo $nav_tab_active_class; ?>"<?php echo $nav_aria_current; ?>><?php esc_html_e( 'Edit Menus' ); ?></a>
    689689                <?php
    690690                if ( $num_locations && $menu_count ) {
    691691                        $active_tab_class = '';
     
    836836                        <span class="screen-reader-text"><?php _e( 'Click the Save Menu button to save your changes.' ); ?></span>
    837837                </span><!-- /add-edit-menu-action -->
    838838                <?php else : ?>
    839                         <form method="get" action="<?php echo admin_url( 'nav-menus.php' ); ?>">
     839                        <form method="get" action="<?php echo esc_url( admin_url( 'nav-menus.php' ) ); ?>">
    840840                        <input type="hidden" name="action" value="edit" />
    841841                        <label for="select-menu-to-edit" class="selected-menu"><?php _e( 'Select a menu to edit:' ); ?></label>
    842842                        <select name="menu" id="select-menu-to-edit">
  • wp-admin/privacy.php

     
    1919
    2020        <div class="about__header">
    2121                <div class="about__header-image">
    22                         <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo admin_url( 'images/about-badge.svg' ); ?>" />
     22                        <img alt="<?php _e( 'Code is Poetry' ); ?>" src="<?php echo esc_url( admin_url( 'images/about-badge.svg' ) ); ?>" />
    2323                </div>
    2424
    2525                <div class="about__header-container">
  • wp-admin/themes.php

     
    250250        </h1>
    251251
    252252        <?php if ( ! is_multisite() && current_user_can( 'install_themes' ) ) : ?>
    253                 <a href="<?php echo admin_url( 'theme-install.php' ); ?>" class="hide-if-no-js page-title-action"><?php echo esc_html_x( 'Add New', 'theme' ); ?></a>
     253                <a href="<?php echo esc_url( admin_url( 'theme-install.php' ) ); ?>" class="hide-if-no-js page-title-action"><?php echo esc_html_x( 'Add New', 'theme' ); ?></a>
    254254        <?php endif; ?>
    255255
    256256        <form class="search-form"></form>
  • wp-admin/upload.php

     
    8787                <?php
    8888                if ( current_user_can( 'upload_files' ) ) {
    8989                        ?>
    90                         <a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action aria-button-if-js"><?php echo esc_html_x( 'Add New', 'file' ); ?></a>
     90                        <a href="<?php echo esc_url( admin_url( 'media-new.php' ) ); ?>" class="page-title-action aria-button-if-js"><?php echo esc_html_x( 'Add New', 'file' ); ?></a>
    9191                                                                <?php
    9292                }
    9393                ?>
     
    270270<?php
    271271if ( current_user_can( 'upload_files' ) ) {
    272272        ?>
    273         <a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'file' ); ?></a>
     273        <a href="<?php echo esc_url( admin_url( 'media-new.php' ) ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'file' ); ?></a>
    274274                                                <?php
    275275}
    276276
  • wp-admin/users.php

     
    617617                <?php
    618618                if ( current_user_can( 'create_users' ) ) {
    619619                        ?>
    620         <a href="<?php echo admin_url( 'user-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
     620        <a href="<?php echo esc_url( admin_url( 'user-new.php' ) ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
    621621<?php } elseif ( is_multisite() && current_user_can( 'promote_users' ) ) { ?>
    622         <a href="<?php echo admin_url( 'user-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add Existing', 'user' ); ?></a>
     622        <a href="<?php echo esc_url( admin_url( 'user-new.php' ) ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add Existing', 'user' ); ?></a>
    623623                        <?php
    624624}
    625625
  • wp-includes/class-wp-embed.php

     
    8888                ?>
    8989<script type="text/javascript">
    9090        jQuery(document).ready(function($){
    91                 $.get("<?php echo admin_url( 'admin-ajax.php?action=oembed-cache&post=' . $post->ID, 'relative' ); ?>");
     91                $.get("<?php echo esc_url( admin_url( 'admin-ajax.php?action=oembed-cache&post=' . $post->ID, 'relative' ) ); ?>");
    9292        });
    9393</script>
    9494                <?php