#20735 closed enhancement (duplicate)
Adding tags to form element of categories.
Reported by: | m.ibrahim | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 3.3.2 |
Component: | Taxonomy | Keywords: | needs-patch good-first-bug needs-testing |
Focuses: | Cc: |
Description
Just like the post form in posts you can use the hook of "post_edit_form_tag" to add new tags to the form element of creating or editing new post.
but there is no hook for categories form to do that I think adding new element will be helpful feature.
Note: after some debugging I found that the hook can be add in:
#File: your wordpress directory/wp-admin/edit-tag-form.php
#Line: 33
# Find : <form name="edittag" id="edittag" method="post" action="edit-tags.php" class="validate">
# Relpace: <form name="edittag" id="edittag" method="post" action="edit-tags.php" class="validate"<?php do_action('categoery_edit_form_tag'); ?>>
Thanks
Change History (6)
#2
@
10 years ago
- Keywords good-first-bug added
- Milestone changed from Awaiting Review to Future Release
#4
@
10 years ago
- Keywords needs-testing added
Yes, do_action( "{$taxonomy}_term_edit_form_tag" );
was added in 3.7.0. Does that work?
#5
@
10 years ago
- Resolution set to worksforme
- Status changed from new to closed
Tested with the following code to add some output in 4.3-alpha-32280-src
with the following code and it works as expected.
function _test_trac_20735_term_edit_form_tag_action() { echo ' enctype="multipart/form-data"'; } add_action( 'category_term_edit_form_tag', '_test_trac_20735_term_edit_form_tag_action' ); add_action( 'post_tag_term_edit_form_tag', '_test_trac_20735_term_edit_form_tag_action' );
Looks like this has been implemented already, ticket can be closed.