Make WordPress Core

Ticket #4218: 4218.diff

File 4218.diff, 1.1 KB (added by rob1n, 18 years ago)
  • wp-includes/functions.php

     
    15061506function wp_maybe_load_widgets() {
    15071507        if ( !function_exists( 'dynamic_sidebar' ) ) {
    15081508                require_once ABSPATH . WPINC . '/widgets.php';
     1509               
     1510                if ( strpos( $_SERVER['REQUEST_URI'], 'wp-admin' ) !== false && isset( $GLOBALS['submenu'] ) ) {
     1511                        $GLOBALS['submenu']['themes.php'][7] = array( __( 'Widgets' ), 'edit_themes', 'widgets.php' );
     1512                }
    15091513        }
    15101514}
    15111515
  • wp-admin/menu.php

     
    6767$submenu['plugins.php'][10] = array(__('Plugin Editor'), 'edit_plugins', 'plugin-editor.php');
    6868
    6969$submenu['themes.php'][5] = array(__('Themes'), 'switch_themes', 'themes.php');
    70 $submenu['themes.php'][7] = array( __( 'Widgets' ), 'edit_themes', 'widgets.php' );
    7170$submenu['themes.php'][10] = array(__('Theme Editor'), 'edit_themes', 'theme-editor.php');
    7271
    7372// Create list of page plugin hook names.