Action hook '{$taxonomy}_edit_form'

in WP Core File wp-admin/edit-tag-form.php at line 296

View Source

{$taxonomy}_edit_form

Action Hook
Description
Fires at the end of the Edit Term form for all taxonomies. The dynamic portion of the hook name, `$taxonomy`, refers to the taxonomy slug. Possible hook names include: - `category_edit_form` - `post_tag_edit_form`

Hook Information

File Location wp-admin/edit-tag-form.php View on GitHub
Hook Type Action
Line Number 296

Hook Parameters

Type Name Description
WP_Term $tag Current taxonomy term object.
string $taxonomy Current taxonomy slug.

Usage Examples

Basic Usage
<?php
// Hook into {$taxonomy}_edit_form
add_action('{$taxonomy}_edit_form', 'my_custom_function', 10, 2);

function my_custom_function($tag, $taxonomy) {
    // Your custom code here
}

Source Code Context

wp-admin/edit-tag-form.php:296 - How this hook is used in WordPress core
<?php
 291   * @since 3.0.0
 292   *
 293   * @param WP_Term $tag      Current taxonomy term object.
 294   * @param string  $taxonomy Current taxonomy slug.
 295   */
 296  do_action( "{$taxonomy}_edit_form", $tag, $taxonomy );
 297  ?>
 298  
 299  <div class="edit-tag-actions">
 300  
 301  	<?php submit_button( __( 'Update' ), 'primary', null, false ); ?>

PHP Documentation

<?php
/**
 * Fires at the end of the Edit Term form for all taxonomies.
 *
 * The dynamic portion of the hook name, `$taxonomy`, refers to the taxonomy slug.
 *
 * Possible hook names include:
 *
 *  - `category_edit_form`
 *  - `post_tag_edit_form`
 *
 * @since 3.0.0
 *
 * @param WP_Term $tag      Current taxonomy term object.
 * @param string  $taxonomy Current taxonomy slug.
 */
Quick Info
  • Hook Type: Action
  • Parameters: 2
  • File: wp-admin/edit-tag-form.php
Related Hooks

Related hooks will be displayed here in future updates.