2008-01-25 20:29:01 +01:00
< ? php
2008-08-16 09:27:34 +02:00
/**
* Edit tag form for inclusion in administration panels .
*
* @ package WordPress
* @ subpackage Administration
*/
2008-10-25 10:01:37 +02:00
if ( empty ( $tag_ID ) ) { ?>
< div id = " message " class = " updated fade " >< p >< strong >< ? php _e ( 'A tag was not selected for editing.' ); ?> </strong></p></div>
< ? php
return ;
2008-01-25 20:29:01 +01:00
}
2008-10-25 10:01:37 +02:00
do_action ( 'edit_tag_form_pre' , $tag ); ?>
2008-01-25 20:29:01 +01:00
< div class = " wrap " >
2008-11-27 00:35:23 +01:00
< ? php screen_icon (); ?>
2008-10-25 10:01:37 +02:00
< h2 >< ? php _e ( 'Edit Tag' ); ?> </h2>
2008-01-25 20:29:01 +01:00
< div id = " ajax-response " ></ div >
2008-10-25 10:01:37 +02:00
< form name = " edittag " id = " edittag " method = " post " action = " edit-tags.php " class = " validate " >
< input type = " hidden " name = " action " value = " editedtag " />
2008-01-25 20:29:01 +01:00
< input type = " hidden " name = " tag_ID " value = " <?php echo $tag->term_id ?> " />
2009-04-28 07:58:45 +02:00
< input type = " hidden " name = " taxonomy " value = " <?php echo attr( $taxonomy ) ?> " />
2008-10-25 10:01:37 +02:00
< ? php wp_original_referer_field ( true , 'previous' ); wp_nonce_field ( 'update-tag_' . $tag_ID ); ?>
2008-02-24 05:33:10 +01:00
< table class = " form-table " >
2008-01-25 20:29:01 +01:00
< tr class = " form-field form-required " >
2008-02-20 21:30:39 +01:00
< th scope = " row " valign = " top " >< label for = " name " >< ? php _e ( 'Tag name' ) ?> </label></th>
2009-04-28 07:58:45 +02:00
< td >< input name = " name " id = " name " type = " text " value = " <?php if ( isset( $tag->name ) ) echo attr( $tag->name ); ?> " size = " 40 " aria - required = " true " />
2008-03-11 08:23:07 +01:00
< p >< ? php _e ( 'The name is how the tag appears on your site.' ); ?> </p></td>
2008-01-25 20:29:01 +01:00
</ tr >
< tr class = " form-field " >
2008-02-20 21:30:39 +01:00
< th scope = " row " valign = " top " >< label for = " slug " >< ? php _e ( 'Tag slug' ) ?> </label></th>
2009-04-28 07:58:45 +02:00
< td >< input name = " slug " id = " slug " type = " text " value = " <?php if ( isset( $tag->slug ) ) echo attr(apply_filters('editable_slug', $tag->slug )); ?> " size = " 40 " />
2008-03-11 08:23:07 +01:00
< p >< ? php _e ( 'The “slug” is the URL-friendly version of the name. It is usually all lowercase and contains only letters, numbers, and hyphens.' ); ?> </p></td>
2008-01-25 20:29:01 +01:00
</ tr >
2009-04-09 18:00:40 +02:00
< tr class = " form-field " >
< th scope = " row " valign = " top " >< label for = " description " >< ? php _e ( 'Description' ) ?> </label></th>
< td >< textarea name = " description " id = " description " rows = " 5 " cols = " 50 " style = " width: 97%; " >< ? php echo wp_specialchars ( $tag -> description ); ?> </textarea><br />
< ? php _e ( 'The description is not prominent by default, however some themes may show it.' ); ?> </td>
</ tr >
2008-01-25 20:29:01 +01:00
</ table >
2008-12-09 10:07:36 +01:00
< p class = " submit " >< input type = " submit " class = " button-primary " name = " submit " value = " <?php _e('Update Tag'); ?> " /></ p >
2008-01-25 20:29:01 +01:00
< ? php do_action ( 'edit_tag_form' , $tag ); ?>
</ form >
</ div >