diff --git a/wp-content/themes/twentyeleven/inc/theme-options.php b/wp-content/themes/twentyeleven/inc/theme-options.php index 4be7fbf45..f1d6c4b3d 100644 --- a/wp-content/themes/twentyeleven/inc/theme-options.php +++ b/wp-content/themes/twentyeleven/inc/theme-options.php @@ -112,28 +112,35 @@ function twentyeleven_theme_options_add_page() { add_action( 'admin_menu', 'twentyeleven_theme_options_add_page' ); function twentyeleven_theme_options_help() { - if ( ! method_exists( get_current_screen(), 'add_help_tab' ) ) - return; - get_current_screen()->add_help_tab( array( - 'title' => __( 'Overview', 'twentyeleven' ), - 'id' => 'theme-options-help', - 'content' => - '
' . __( 'Some themes provide customization options that are grouped together on a Theme Options screen. If you change themes, options may change or disappear, as they are theme-specific. Your current theme, Twenty Eleven, provides the following Theme Options:', 'twentyeleven' ) . '
' . + $help = '' . __( 'Some themes provide customization options that are grouped together on a Theme Options screen. If you change themes, options may change or disappear, as they are theme-specific. Your current theme, Twenty Eleven, provides the following Theme Options:', 'twentyeleven' ) . '
' . '' . __( 'Remember to click "Save Changes" to save any changes you have made to the theme options.', 'twentyeleven' ) . '
' - ) - ); + '' . __( 'Remember to click "Save Changes" to save any changes you have made to the theme options.', 'twentyeleven' ) . '
'; - get_current_screen()->set_help_sidebar( - '' . __( 'For more information:', 'twentyeleven' ) . '
' . + $sidebar = '' . __( 'For more information:', 'twentyeleven' ) . '
' . '' . __( 'Documentation on Theme Options', 'twentyeleven' ) . '
' . - '' . __( 'Support Forums', 'twentyeleven' ) . '
' - ); + '' . __( 'Support Forums', 'twentyeleven' ) . '
'; + + $screen = get_current_screen(); + + if ( method_exists( $screen, 'add_help_tab' ) ) { + // WordPress 3.3 + $screen->add_help_tab( array( + 'title' => __( 'Overview', 'twentyeleven' ), + 'id' => 'theme-options-help', + 'content' => $help, + ) + ); + + $screen->set_help_sidebar( $sidebar ); + } else { + // WordPress 3.2 + add_contextual_help( $screen, $help . $sidebar ); + } } /**