You can use the dynamic {$taxonomy}_term_new_form_tag
action, where you replace {$taxonomy}
with your taxonomy slug.
Example1)
For the post_tag
taxonomy:
add_action( 'post_tag_term_new_form_tag', function()
{
printf( '><div class="form-field">%s</div', esc_html__( 'Some content', 'mydomain' ) );
}, PHP_INT_MAX );
1) Update:
I didn’t noticed at first that this is inside the <form>
tag, so this is a hack to adjust to that and the PHP_INT_MAX
priority is here to run it as late as possible. But I don’t like this approach, the {$taxonomy}_add_form_fields
is more suitable, but then you would need to move it up via CSS (flex order?) or javascript.
It’s also possible to hijack the fourth esc_attr()
call, after post_tag_term_new_form_tag
is fired up, via the attribute_escape
filter, i.e. the one inside the wp_nounce_field()
but that sounds too unstable.