[wp-hackers] Update post status

Russ Gilbert russgilbert at gmail.com
Thu Nov 19 21:52:18 UTC 2009


I'm fairly new myself, but just had to tackle that same task this week.

http://codex.wordpress.org/Function_Reference is your friend.

The function in question is:

http://codex.wordpress.org/Function_Reference/wp_update_post

(works on both posts and pages)



-----Original Message-----
From: wp-hackers-bounces at lists.automattic.com
[mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Jeff Rose
Sent: Thursday, November 19, 2009 1:42 PM
To: wp-hackers at lists.automattic.com
Subject: [wp-hackers] Update post status

I'm a relative newbie developer and my latest plugin needs to
programatically change the status of a post and I'm wondering the proper
steps to doing this.

This would be going from a DRAFT status to either a FUTURE or PUBLISHED
status depending on the chosen option.

Any advice is appreciated.

http://www.jeffrose.ca/twitter
_______________________________________________
wp-hackers mailing list
wp-hackers at lists.automattic.com
http://lists.automattic.com/mailman/listinfo/wp-hackers



More information about the wp-hackers mailing list