WordPress.org

Ready to get started?Download WordPress

Forums

programming: how to append tag to post with some criteria? (1 post)

  1. kkarpieszuk
    Member
    Posted 4 years ago #

    hi

    I am writing plugin. I want to add tag "video" to post, when it is published or edited if this post has some special value in Custom Field.

    I know how to check if post has this custom field.
    I know how to make some action when post is published: add_action('publish_post'...
    but i don't know how to add tag 'video' in this action. what should be in function?

Topic Closed

This topic has been closed to new replies.

About this Topic