Changeset 15183 for trunk/wp-admin/includes/meta-boxes.php
- Timestamp:
- 06/09/2010 09:59:13 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/meta-boxes.php
r14967 r15183 243 243 */ 244 244 function post_tags_meta_box($post, $box) { 245 $tax_name = esc_attr(substr($box['id'], 8)); 246 $taxonomy = get_taxonomy($tax_name); 245 $defaults = array('taxonomy' => 'post_tag'); 246 if ( !isset($box['args']) || !is_array($box['args']) ) 247 $args = array(); 248 else 249 $args = $box['args']; 250 extract( wp_parse_args($args, $defaults), EXTR_SKIP ); 251 $tax_name = esc_attr($taxonomy); 252 $taxonomy = get_taxonomy($taxonomy); 253 247 254 $helps = isset( $taxonomy->helps ) ? esc_attr( $taxonomy->helps ) : esc_attr__('Separate tags with commas.'); 248 $help_hint = isset( $taxonomy->help_hint ) ? $taxonomy->help_hint : __('Add new tag');249 255 $help_nojs = isset( $taxonomy->help_nojs ) ? $taxonomy->help_nojs : __('Add or remove tags'); 250 256 $help_cloud = isset( $taxonomy->help_cloud ) ? $taxonomy->help_cloud : __('Choose from the most used tags'); … … 260 266 <div class="ajaxtag hide-if-no-js"> 261 267 <label class="screen-reader-text" for="new-tag-<?php echo $tax_name; ?>"><?php echo $box['title']; ?></label> 262 <div class="taghint"><?php echo $ help_hint; ?></div>268 <div class="taghint"><?php echo $taxonomy->labels->add_new_item; ?></div> 263 269 <p><input type="text" id="new-tag-<?php echo $tax_name; ?>" name="newtag[<?php echo $tax_name; ?>]" class="newtag form-input-tip" size="16" autocomplete="off" value="" /> 264 270 <input type="button" class="button tagadd" value="<?php esc_attr_e('Add'); ?>" tabindex="3" /></p>
Note: See TracChangeset
for help on using the changeset viewer.