author | ymh <ymh.work@gmail.com> |
Fri, 05 Sep 2025 18:52:52 +0200 | |
changeset 22 | 8c2e4d02f4ef |
parent 21 | 48c4eec2b7e6 |
permissions | -rw-r--r-- |
0 | 1 |
<?php |
2 |
/** |
|
3 |
* Edit tag form for inclusion in administration panels. |
|
4 |
* |
|
5 |
* @package WordPress |
|
6 |
* @subpackage Administration |
|
7 |
*/ |
|
8 |
||
16 | 9 |
// Don't load directly. |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
10 |
if ( ! defined( 'ABSPATH' ) ) { |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
11 |
die( '-1' ); |
0 | 12 |
} |
13 |
||
16 | 14 |
// Back compat hooks. |
15 |
if ( 'category' === $taxonomy ) { |
|
5 | 16 |
/** |
9 | 17 |
* Fires before the Edit Category form. |
5 | 18 |
* |
19 |
* @since 2.1.0 |
|
16 | 20 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_pre_edit_form'} instead. |
5 | 21 |
* |
9 | 22 |
* @param WP_Term $tag Current category term object. |
5 | 23 |
*/ |
16 | 24 |
do_action_deprecated( 'edit_category_form_pre', array( $tag ), '3.0.0', '{$taxonomy}_pre_edit_form' ); |
25 |
} elseif ( 'link_category' === $taxonomy ) { |
|
5 | 26 |
/** |
27 |
* Fires before the Edit Link Category form. |
|
28 |
* |
|
29 |
* @since 2.3.0 |
|
16 | 30 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_pre_edit_form'} instead. |
5 | 31 |
* |
9 | 32 |
* @param WP_Term $tag Current link category term object. |
5 | 33 |
*/ |
16 | 34 |
do_action_deprecated( 'edit_link_category_form_pre', array( $tag ), '3.0.0', '{$taxonomy}_pre_edit_form' ); |
5 | 35 |
} else { |
36 |
/** |
|
37 |
* Fires before the Edit Tag form. |
|
38 |
* |
|
39 |
* @since 2.5.0 |
|
16 | 40 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_pre_edit_form'} instead. |
5 | 41 |
* |
9 | 42 |
* @param WP_Term $tag Current tag term object. |
5 | 43 |
*/ |
16 | 44 |
do_action_deprecated( 'edit_tag_form_pre', array( $tag ), '3.0.0', '{$taxonomy}_pre_edit_form' ); |
5 | 45 |
} |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
46 |
|
22
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
47 |
$wp_http_referer = ! empty( $_REQUEST['wp_http_referer'] ) ? sanitize_url( $_REQUEST['wp_http_referer'] ) : ''; |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
48 |
$wp_http_referer = remove_query_arg( array( 'action', 'message', 'tag_ID' ), $wp_http_referer ); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
49 |
|
18 | 50 |
// Also used by Edit Tags. |
16 | 51 |
require_once ABSPATH . 'wp-admin/includes/edit-tag-messages.php'; |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
52 |
|
5 | 53 |
/** |
54 |
* Fires before the Edit Term form for all taxonomies. |
|
55 |
* |
|
56 |
* The dynamic portion of the hook name, `$taxonomy`, refers to |
|
57 |
* the taxonomy slug. |
|
58 |
* |
|
18 | 59 |
* Possible hook names include: |
60 |
* |
|
61 |
* - `category_pre_edit_form` |
|
62 |
* - `post_tag_pre_edit_form` |
|
63 |
* |
|
5 | 64 |
* @since 3.0.0 |
65 |
* |
|
9 | 66 |
* @param WP_Term $tag Current taxonomy term object. |
67 |
* @param string $taxonomy Current $taxonomy slug. |
|
5 | 68 |
*/ |
69 |
do_action( "{$taxonomy}_pre_edit_form", $tag, $taxonomy ); ?> |
|
0 | 70 |
|
71 |
<div class="wrap"> |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
72 |
<h1><?php echo $tax->labels->edit_item; ?></h1> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
73 |
|
9 | 74 |
<?php |
22
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
75 |
$class = ( isset( $_REQUEST['error'] ) ) ? 'error' : 'success'; |
9 | 76 |
|
77 |
if ( $message ) { |
|
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
78 |
$message = '<p><strong>' . $message . '</strong></p>'; |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
79 |
if ( $wp_http_referer ) { |
22
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
80 |
$message .= sprintf( |
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
81 |
'<p><a href="%1$s">%2$s</a></p>', |
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
82 |
esc_url( wp_validate_redirect( sanitize_url( $wp_http_referer ), admin_url( 'term.php?taxonomy=' . $taxonomy ) ) ), |
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
83 |
esc_html( $tax->labels->back_to_items ) |
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
84 |
); |
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
85 |
} |
22
8c2e4d02f4ef
Update WordPress to latest version (6.7)
ymh <ymh.work@gmail.com>
parents:
21
diff
changeset
|
86 |
|
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
87 |
wp_admin_notice( |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
88 |
$message, |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
89 |
array( |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
90 |
'type' => $class, |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
91 |
'id' => 'message', |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
92 |
'paragraph_wrap' => false, |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
93 |
) |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
94 |
); |
9 | 95 |
} |
96 |
?> |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
97 |
|
0 | 98 |
<div id="ajax-response"></div> |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
99 |
|
9 | 100 |
<form name="edittag" id="edittag" method="post" action="edit-tags.php" class="validate" |
101 |
<?php |
|
5 | 102 |
/** |
103 |
* Fires inside the Edit Term form tag. |
|
104 |
* |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
105 |
* The dynamic portion of the hook name, `$taxonomy`, refers to the taxonomy slug. |
5 | 106 |
* |
18 | 107 |
* Possible hook names include: |
108 |
* |
|
109 |
* - `category_term_edit_form_tag` |
|
110 |
* - `post_tag_term_edit_form_tag` |
|
111 |
* |
|
5 | 112 |
* @since 3.7.0 |
113 |
*/ |
|
114 |
do_action( "{$taxonomy}_term_edit_form_tag" ); |
|
9 | 115 |
?> |
116 |
> |
|
18 | 117 |
<input type="hidden" name="action" value="editedtag" /> |
118 |
<input type="hidden" name="tag_ID" value="<?php echo esc_attr( $tag_ID ); ?>" /> |
|
119 |
<input type="hidden" name="taxonomy" value="<?php echo esc_attr( $taxonomy ); ?>" /> |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
120 |
<?php |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
121 |
wp_original_referer_field( true, 'previous' ); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
122 |
wp_nonce_field( 'update-tag_' . $tag_ID ); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
123 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
124 |
/** |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
125 |
* Fires at the beginning of the Edit Term form. |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
126 |
* |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
127 |
* At this point, the required hidden fields and nonces have already been output. |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
128 |
* |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
129 |
* The dynamic portion of the hook name, `$taxonomy`, refers to the taxonomy slug. |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
130 |
* |
18 | 131 |
* Possible hook names include: |
132 |
* |
|
133 |
* - `category_term_edit_form_top` |
|
134 |
* - `post_tag_term_edit_form_top` |
|
135 |
* |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
136 |
* @since 4.5.0 |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
137 |
* |
9 | 138 |
* @param WP_Term $tag Current taxonomy term object. |
139 |
* @param string $taxonomy Current $taxonomy slug. |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
140 |
*/ |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
141 |
do_action( "{$taxonomy}_term_edit_form_top", $tag, $taxonomy ); |
9 | 142 |
|
143 |
$tag_name_value = ''; |
|
144 |
if ( isset( $tag->name ) ) { |
|
145 |
$tag_name_value = esc_attr( $tag->name ); |
|
146 |
} |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
147 |
?> |
9 | 148 |
<table class="form-table" role="presentation"> |
5 | 149 |
<tr class="form-field form-required term-name-wrap"> |
150 |
<th scope="row"><label for="name"><?php _ex( 'Name', 'term name' ); ?></label></th> |
|
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
151 |
<td><input name="name" id="name" type="text" value="<?php echo $tag_name_value; ?>" size="40" aria-required="true" aria-describedby="name-description" /> |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
152 |
<p class="description" id="name-description"><?php echo $tax->labels->name_field_description; ?></p></td> |
0 | 153 |
</tr> |
5 | 154 |
<tr class="form-field term-slug-wrap"> |
155 |
<th scope="row"><label for="slug"><?php _e( 'Slug' ); ?></label></th> |
|
156 |
<?php |
|
157 |
/** |
|
18 | 158 |
* Filters the editable slug for a post or term. |
5 | 159 |
* |
160 |
* Note: This is a multi-use hook in that it is leveraged both for editable |
|
161 |
* post URIs and term slugs. |
|
162 |
* |
|
163 |
* @since 2.6.0 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
164 |
* @since 4.4.0 The `$tag` parameter was added. |
5 | 165 |
* |
9 | 166 |
* @param string $slug The editable slug. Will be either a term slug or post URI depending |
167 |
* upon the context in which it is evaluated. |
|
18 | 168 |
* @param WP_Term|WP_Post $tag Term or post object. |
5 | 169 |
*/ |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
170 |
$slug = isset( $tag->slug ) ? apply_filters( 'editable_slug', $tag->slug, $tag ) : ''; |
5 | 171 |
?> |
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
172 |
<td><input name="slug" id="slug" type="text" value="<?php echo esc_attr( $slug ); ?>" size="40" aria-describedby="slug-description" /> |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
173 |
<p class="description" id="slug-description"><?php echo $tax->labels->slug_field_description; ?></p></td> |
0 | 174 |
</tr> |
9 | 175 |
<?php if ( is_taxonomy_hierarchical( $taxonomy ) ) : ?> |
5 | 176 |
<tr class="form-field term-parent-wrap"> |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
177 |
<th scope="row"><label for="parent"><?php echo esc_html( $tax->labels->parent_item ); ?></label></th> |
0 | 178 |
<td> |
5 | 179 |
<?php |
180 |
$dropdown_args = array( |
|
181 |
'hide_empty' => 0, |
|
182 |
'hide_if_empty' => false, |
|
183 |
'taxonomy' => $taxonomy, |
|
184 |
'name' => 'parent', |
|
185 |
'orderby' => 'name', |
|
186 |
'selected' => $tag->parent, |
|
187 |
'exclude_tree' => $tag->term_id, |
|
188 |
'hierarchical' => true, |
|
189 |
'show_option_none' => __( 'None' ), |
|
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
190 |
'aria_describedby' => 'parent-description', |
5 | 191 |
); |
192 |
||
193 |
/** This filter is documented in wp-admin/edit-tags.php */ |
|
194 |
$dropdown_args = apply_filters( 'taxonomy_parent_dropdown_args', $dropdown_args, $taxonomy, 'edit' ); |
|
9 | 195 |
wp_dropdown_categories( $dropdown_args ); |
196 |
?> |
|
16 | 197 |
<?php if ( 'category' === $taxonomy ) : ?> |
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
198 |
<p class="description" id="parent-description"><?php _e( 'Categories, unlike tags, can have a hierarchy. You might have a Jazz category, and under that have children categories for Bebop and Big Band. Totally optional.' ); ?></p> |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
199 |
<?php else : ?> |
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
200 |
<p class="description" id="parent-description"><?php echo $tax->labels->parent_field_description; ?></p> |
0 | 201 |
<?php endif; ?> |
202 |
</td> |
|
203 |
</tr> |
|
204 |
<?php endif; // is_taxonomy_hierarchical() ?> |
|
5 | 205 |
<tr class="form-field term-description-wrap"> |
206 |
<th scope="row"><label for="description"><?php _e( 'Description' ); ?></label></th> |
|
21
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
207 |
<td><textarea name="description" id="description" rows="5" cols="50" class="large-text" aria-describedby="description-description"><?php echo $tag->description; // textarea_escaped ?></textarea> |
48c4eec2b7e6
Add CLAUDE.md documentation and sync WordPress core files
ymh <ymh.work@gmail.com>
parents:
19
diff
changeset
|
208 |
<p class="description" id="description-description"><?php echo $tax->labels->desc_field_description; ?></p></td> |
0 | 209 |
</tr> |
210 |
<?php |
|
16 | 211 |
// Back compat hooks. |
212 |
if ( 'category' === $taxonomy ) { |
|
5 | 213 |
/** |
214 |
* Fires after the Edit Category form fields are displayed. |
|
215 |
* |
|
216 |
* @since 2.9.0 |
|
16 | 217 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_edit_form_fields'} instead. |
5 | 218 |
* |
9 | 219 |
* @param WP_Term $tag Current category term object. |
5 | 220 |
*/ |
16 | 221 |
do_action_deprecated( 'edit_category_form_fields', array( $tag ), '3.0.0', '{$taxonomy}_edit_form_fields' ); |
222 |
} elseif ( 'link_category' === $taxonomy ) { |
|
5 | 223 |
/** |
224 |
* Fires after the Edit Link Category form fields are displayed. |
|
225 |
* |
|
226 |
* @since 2.9.0 |
|
16 | 227 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_edit_form_fields'} instead. |
5 | 228 |
* |
9 | 229 |
* @param WP_Term $tag Current link category term object. |
5 | 230 |
*/ |
16 | 231 |
do_action_deprecated( 'edit_link_category_form_fields', array( $tag ), '3.0.0', '{$taxonomy}_edit_form_fields' ); |
5 | 232 |
} else { |
233 |
/** |
|
234 |
* Fires after the Edit Tag form fields are displayed. |
|
235 |
* |
|
236 |
* @since 2.9.0 |
|
16 | 237 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_edit_form_fields'} instead. |
5 | 238 |
* |
9 | 239 |
* @param WP_Term $tag Current tag term object. |
5 | 240 |
*/ |
16 | 241 |
do_action_deprecated( 'edit_tag_form_fields', array( $tag ), '3.0.0', '{$taxonomy}_edit_form_fields' ); |
5 | 242 |
} |
243 |
/** |
|
244 |
* Fires after the Edit Term form fields are displayed. |
|
245 |
* |
|
246 |
* The dynamic portion of the hook name, `$taxonomy`, refers to |
|
247 |
* the taxonomy slug. |
|
248 |
* |
|
18 | 249 |
* Possible hook names include: |
250 |
* |
|
251 |
* - `category_edit_form_fields` |
|
252 |
* - `post_tag_edit_form_fields` |
|
253 |
* |
|
5 | 254 |
* @since 3.0.0 |
255 |
* |
|
9 | 256 |
* @param WP_Term $tag Current taxonomy term object. |
257 |
* @param string $taxonomy Current taxonomy slug. |
|
5 | 258 |
*/ |
259 |
do_action( "{$taxonomy}_edit_form_fields", $tag, $taxonomy ); |
|
0 | 260 |
?> |
261 |
</table> |
|
262 |
<?php |
|
16 | 263 |
// Back compat hooks. |
264 |
if ( 'category' === $taxonomy ) { |
|
5 | 265 |
/** This action is documented in wp-admin/edit-tags.php */ |
16 | 266 |
do_action_deprecated( 'edit_category_form', array( $tag ), '3.0.0', '{$taxonomy}_add_form' ); |
267 |
} elseif ( 'link_category' === $taxonomy ) { |
|
5 | 268 |
/** This action is documented in wp-admin/edit-tags.php */ |
16 | 269 |
do_action_deprecated( 'edit_link_category_form', array( $tag ), '3.0.0', '{$taxonomy}_add_form' ); |
5 | 270 |
} else { |
271 |
/** |
|
272 |
* Fires at the end of the Edit Term form. |
|
273 |
* |
|
274 |
* @since 2.5.0 |
|
16 | 275 |
* @deprecated 3.0.0 Use {@see '{$taxonomy}_edit_form'} instead. |
5 | 276 |
* |
9 | 277 |
* @param WP_Term $tag Current taxonomy term object. |
5 | 278 |
*/ |
16 | 279 |
do_action_deprecated( 'edit_tag_form', array( $tag ), '3.0.0', '{$taxonomy}_edit_form' ); |
5 | 280 |
} |
281 |
/** |
|
282 |
* Fires at the end of the Edit Term form for all taxonomies. |
|
283 |
* |
|
284 |
* The dynamic portion of the hook name, `$taxonomy`, refers to the taxonomy slug. |
|
285 |
* |
|
18 | 286 |
* Possible hook names include: |
287 |
* |
|
288 |
* - `category_edit_form` |
|
289 |
* - `post_tag_edit_form` |
|
290 |
* |
|
5 | 291 |
* @since 3.0.0 |
292 |
* |
|
9 | 293 |
* @param WP_Term $tag Current taxonomy term object. |
294 |
* @param string $taxonomy Current taxonomy slug. |
|
5 | 295 |
*/ |
296 |
do_action( "{$taxonomy}_edit_form", $tag, $taxonomy ); |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
297 |
?> |
0 | 298 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
299 |
<div class="edit-tag-actions"> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
300 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
301 |
<?php submit_button( __( 'Update' ), 'primary', null, false ); ?> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
302 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
303 |
<?php if ( current_user_can( 'delete_term', $tag->term_id ) ) : ?> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
304 |
<span id="delete-link"> |
18 | 305 |
<a class="delete" href="<?php echo esc_url( admin_url( wp_nonce_url( "edit-tags.php?action=delete&taxonomy=$taxonomy&tag_ID=$tag->term_id", 'delete-tag_' . $tag->term_id ) ) ); ?>"><?php _e( 'Delete' ); ?></a> |
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
306 |
</span> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
307 |
<?php endif; ?> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
308 |
|
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
309 |
</div> |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
310 |
|
0 | 311 |
</form> |
312 |
</div> |
|
5 | 313 |
|
314 |
<?php if ( ! wp_is_mobile() ) : ?> |
|
0 | 315 |
<script type="text/javascript"> |
316 |
try{document.forms.edittag.name.focus();}catch(e){} |
|
317 |
</script> |
|
9 | 318 |
<?php |
319 |
endif; |