Changeset 42211 for trunk/src/wp-includes/class-wp-taxonomy.php
- Timestamp:
- 11/21/2017 03:14:52 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-taxonomy.php
r41162 r42211 127 127 */ 128 128 public $meta_box_cb = null; 129 130 /** 131 * The callback function for sanitizing taxonomy data saved from a meta box. 132 * 133 * @since 5.0.0 134 * @access public 135 * @var callable 136 */ 137 public $meta_box_sanitize_cb = null; 129 138 130 139 /** … … 258 267 'show_admin_column' => false, 259 268 'meta_box_cb' => null, 269 'meta_box_sanitize_cb' => null, 260 270 'capabilities' => array(), 261 271 'rewrite' => true, … … 346 356 $args['name'] = $this->name; 347 357 358 // Default meta box sanitization callback depends on the value of 'meta_box_cb'. 359 if ( null === $args['meta_box_sanitize_cb'] ) { 360 switch ( $args['meta_box_cb'] ) { 361 case 'post_categories_meta_box' : 362 $args['meta_box_sanitize_cb'] = 'taxonomy_meta_box_sanitize_cb_checkboxes'; 363 break; 364 365 case 'post_tags_meta_box' : 366 default : 367 $args['meta_box_sanitize_cb'] = 'taxonomy_meta_box_sanitize_cb_input'; 368 break; 369 } 370 } 371 348 372 foreach ( $args as $property_name => $property_value ) { 349 373 $this->$property_name = $property_value;
Note: See TracChangeset
for help on using the changeset viewer.