( function( $, api ) { /* === Dropdown Taxonomies Control === */ api.controlConstructor['dropdown-taxonomies'] = api.Control.extend( { ready: function() { var control = this; $( 'select', control.container ).change( function() { control.setting.set( $( this ).val() ); } ); } } ); /* === Upsell section === */ api.sectionConstructor['upsell'] = api.Section.extend( { // No events for this type of section. attachEvents: function () {}, // Always make the section active. isContextuallyActive: function () { return true; } } ); } )( jQuery, wp.customize );