- Timestamp:
- 03/01/2016 10:17:20 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-content/themes/twentyfifteen/inc/customizer.php
r34791 r36797 20 20 $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; 21 21 $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 22 23 if ( isset( $wp_customize->selective_refresh ) ) { 24 $wp_customize->selective_refresh->add_partial( 'blogname', array( 25 'selector' => '.site-title a', 26 'container_inclusive' => false, 27 'render_callback' => 'twentyfifteen_customize_partial_blogname', 28 ) ); 29 $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 30 'selector' => '.site-description', 31 'container_inclusive' => false, 32 'render_callback' => 'twentyfifteen_customize_partial_blogdescription', 33 ) ); 34 } 22 35 23 36 // Add color scheme setting and control. … … 69 82 } 70 83 add_action( 'customize_register', 'twentyfifteen_customize_register', 11 ); 84 85 /** 86 * Render the site title for the selective refresh partial. 87 * 88 * @since Twenty Fifteen 1.5 89 * @see twentyfifteen_customize_register() 90 * 91 * @return void 92 */ 93 function twentyfifteen_customize_partial_blogname() { 94 bloginfo( 'name' ); 95 } 96 97 /** 98 * Render the site tagline for the selective refresh partial. 99 * 100 * @since Twenty Fifteen 1.5 101 * @see twentyfifteen_customize_register() 102 * 103 * @return void 104 */ 105 function twentyfifteen_customize_partial_blogdescription() { 106 bloginfo( 'description' ); 107 } 71 108 72 109 /**
Note: See TracChangeset
for help on using the changeset viewer.