Post Status and Post Meta Data
-
I’m working on a post-expires plugin, adapted from the atropos plugin.
I’ve noticed that when the posts status is updated (from draft to published or visa-versa), the meta data I have saved against the post is lost (or loses its connection to the post). This is first time I’ve used meta-data at all (I’m usually a custom field kind guy) and don’t know enough about how the meta relationships are formed. Please could someone advise me how to maintain the connection when the post status changes.
Thank you!
p.s. For those interested, the primary change I am making to atropos is to set expired posts status to “draft’ rather than deleting the post.
The topic ‘Post Status and Post Meta Data’ is closed to new replies.