WordPress.org

Make WordPress Core

Ticket #21564: 21564-r21841.patch

File 21564-r21841.patch, 4.7 KB (added by bpetty, 6 years ago)
  • wp-admin/export.php

    diff --git wp-admin/export.php wp-admin/export.php
    index eaf76fc..468afc9 100644
    if ( !current_user_can('export') ) 
    1616require_once('./includes/export.php');
    1717$title = __('Export');
    1818
    19 function add_js() {
     19function add_js_for_wp_admin_export() {
    2020?>
    2121<script type="text/javascript">
    2222//<![CDATA[
    function add_js() { 
    3636</script>
    3737<?php
    3838}
    39 add_action( 'admin_head', 'add_js' );
     39add_action( 'admin_head', 'add_js_for_wp_admin_export' );
    4040
    4141get_current_screen()->add_help_tab( array(
    4242        'id'      => 'overview',
  • wp-admin/options-general.php

    diff --git wp-admin/options-general.php wp-admin/options-general.php
    index d8a8b80..65fdd0d 100644
    $timezone_format = _x('Y-m-d G:i:s', 'timezone date format'); 
    2323 * @package WordPress
    2424 * @subpackage General_Settings_Screen
    2525 */
    26 function add_js() {
     26function add_js_for_wp_admin_general_options() {
    2727?>
    2828<script type="text/javascript">
    2929//<![CDATA[
    function add_js() { 
    5656</script>
    5757<?php
    5858}
    59 add_action('admin_head', 'add_js');
     59add_action('admin_head', 'add_js_for_wp_admin_general_options');
    6060
    6161$options_help = '<p>' . __('The fields on this screen determine some of the basics of your site setup.') . '</p>' .
    6262        '<p>' . __('Most themes display the site title at the top of every page, in the title bar of the browser, and as the identifying name for syndicated feeds. The tagline is also displayed by many themes.') . '</p>';
  • wp-admin/options-permalink.php

    diff --git wp-admin/options-permalink.php wp-admin/options-permalink.php
    index 9ccb62f..8d79a92 100644
    get_current_screen()->set_help_sidebar( 
    5252 * @package WordPress
    5353 * @subpackage Permalink_Settings_Screen
    5454 */
    55 function add_js() {
     55function add_js_for_wp_admin_permalink_options() {
    5656        ?>
    5757<script type="text/javascript">
    5858//<![CDATA[
    jQuery(document).ready(function() { 
    7070</script>
    7171<?php
    7272}
    73 add_filter('admin_head', 'add_js');
     73add_filter('admin_head', 'add_js_for_wp_admin_permalink_options');
    7474
    7575include('./admin-header.php');
    7676
  • wp-admin/options-reading.php

    diff --git wp-admin/options-reading.php wp-admin/options-reading.php
    index 359ae45..afccaad 100644
    $parent_file = 'options-general.php'; 
    2121 * @package WordPress
    2222 * @subpackage Reading_Settings_Screen
    2323 */
    24 function add_js() {
     24function add_js_for_wp_admin_reading_options() {
    2525?>
    2626<script type="text/javascript">
    2727//<![CDATA[
    function add_js() { 
    3939</script>
    4040<?php
    4141}
    42 add_action('admin_head', 'add_js');
     42add_action('admin_head', 'add_js_for_wp_admin_reading_options');
    4343
    4444get_current_screen()->add_help_tab( array(
    4545        'id'      => 'overview',
  • wp-admin/setup-config.php

    diff --git wp-admin/setup-config.php wp-admin/setup-config.php
    index 5bf19ad..dbfa029 100644
    $step = isset( $_GET['step'] ) ? (int) $_GET['step'] : 0; 
    8585 * @package WordPress
    8686 * @subpackage Installer_WP_Config
    8787 */
    88 function display_header() {
     88function display_setup_config_header() {
    8989        global $wp_version;
    9090
    9191        header( 'Content-Type: text/html; charset=utf-8' );
    function display_header() { 
    101101<body<?php if ( is_rtl() ) echo ' class="rtl"'; ?>>
    102102<h1 id="logo"><img alt="WordPress" src="images/wordpress-logo.png?ver=20120216" /></h1>
    103103<?php
    104 }//end function display_header();
     104}//end function display_setup_config_header();
    105105
    106106switch($step) {
    107107        case 0:
    108                 display_header();
     108                display_setup_config_header();
    109109?>
    110110
    111111<p><?php _e( 'Welcome to WordPress. Before getting started, we need some information on the database. You will need to know the following items before proceeding.' ) ?></p>
    switch($step) { 
    124124        break;
    125125
    126126        case 1:
    127                 display_header();
     127                display_setup_config_header();
    128128        ?>
    129129<form method="post" action="setup-config.php?step=2">
    130130        <p><?php _e( "Below you should enter your database connection details. If you're not sure about these, contact your host." ); ?></p>
    switch($step) { 
    254254        unset( $line );
    255255
    256256        if ( ! is_writable(ABSPATH) ) :
    257                 display_header();
     257                display_setup_config_header();
    258258?>
    259259<p><?php _e( "Sorry, but I can't write the <code>wp-config.php</code> file." ); ?></p>
    260260<p><?php _e( 'You can create the <code>wp-config.php</code> manually and paste the following text into it.' ); ?></p>
    switch($step) { 
    273273                }
    274274                fclose($handle);
    275275                chmod(ABSPATH . 'wp-config.php', 0666);
    276                 display_header();
     276                display_setup_config_header();
    277277?>
    278278<p><?php _e( "All right sparky! You've made it through this part of the installation. WordPress can now communicate with your database. If you are ready, time now to&hellip;" ); ?></p>
    279279