Ticket #19020: 19020-zeo-2011-theme-options.php.diff
| File 19020-zeo-2011-theme-options.php.diff, 2.9 KB (added by , 14 years ago) |
|---|
-
wp-content/themes/twentyeleven/inc/theme-options.php
48 48 ); 49 49 50 50 // Register our settings field group 51 add_settings_section( 51 add_settings_section( 52 52 'general', // Unique identifier for the settings section 53 53 '', // Section title (we don't want one) 54 '__return_false', // Section callback (we don't want anything) 54 '__return_false', // Section callback (we don't want anything) 55 55 'theme_options' // Menu slug, used to uniquely identify the page; see twentyeleven_theme_options_add_page() 56 56 ); 57 57 58 58 // Register our individual settings fields 59 add_settings_field( 59 add_settings_field( 60 60 'color_scheme', // Unique identifier for the field for this section 61 61 __( 'Color Scheme', 'twentyeleven' ), // Setting field label 62 62 'twentyeleven_settings_field_color_scheme', // Function that renders the settings field … … 65 65 ); 66 66 67 67 add_settings_field( 'link_color', __( 'Link Color', 'twentyeleven' ), 'twentyeleven_settings_field_link_color', 'theme_options', 'general' ); 68 add_settings_field( 'layout', __( ' Layout', 'twentyeleven' ), 'twentyeleven_settings_field_layout', 'theme_options', 'general' );68 add_settings_field( 'layout', __( 'Default Layout', 'twentyeleven' ), 'twentyeleven_settings_field_layout', 'theme_options', 'general' ); 69 69 } 70 70 add_action( 'admin_init', 'twentyeleven_theme_options_init' ); 71 71 … … 118 118 get_current_screen()->add_help_tab( array( 119 119 'title' => __( 'Overview', 'twentyeleven' ), 120 120 'id' => 'theme-options-help', 121 'content' => 121 'content' => 122 122 '<p>' . __( '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' ) . '</p>' . 123 123 '<ol>' . 124 124 '<li>' . __( '<strong>Color Scheme</strong>: You can choose a color palette of "Light" (light background with dark text) or "Dark" (dark background with light text) for your site.', 'twentyeleven' ) . '</li>' . … … 237 237 238 238 /** 239 239 * Renders the Color Scheme setting field. 240 * 240 * 241 241 * @since Twenty Eleven 1.3 242 242 */ 243 243 function twentyeleven_settings_field_color_scheme() { … … 261 261 262 262 /** 263 263 * Renders the Link Color setting field. 264 * 264 * 265 265 * @since Twenty Eleven 1.3 266 266 */ 267 267 function twentyeleven_settings_field_link_color() { … … 278 278 279 279 /** 280 280 * Renders the Layout setting field. 281 * 281 * 282 282 * @since Twenty Eleven 1.3 283 283 */ 284 284 function twentyeleven_settings_field_layout() { … … 439 439 440 440 return array_merge( $existing_classes, $classes ); 441 441 } 442 add_filter( 'body_class', 'twentyeleven_layout_classes' ); 443 No newline at end of file 442 add_filter( 'body_class', 'twentyeleven_layout_classes' );