When a user adds a tag to a post, I'm trying to determine if they have permission to post in to that specific tag. If the user is not assigned to a tag that they try adding via the input in the "Tags" meta box, I'd like to display an error along the lines of "you do not have permission to post in $tag_name.`
I know there are hooks for create_tag
, but that doesn't fire until you actually save the post, because the tag doesn't get created until the post is saved. For exiting tags, it looks like set_object_terms
could be useful, but again, that doesn't get fired until you actually save the post.
Does any filter exist when a user enters a tag in the input on in Tags meta meta box, after clicking "add"?
save_post
action then? Do I miss something?