WordPress.org

Support

Support » Plugins and Hacks » Hacks » Change post / page status

Change post / page status

  • Hello,

    I am trying to figure out how to write the code that will allow me to do the following with pages of a WordPress blog?

    “To change a post status, you get the post, change its status field, then call wp_update_post with the new post object”

    Basically I want to be able to list a specific page (in a wp admin options page I will create) and then allow the user to update the status of that page from draft to publish and back from publish to draft.

    Thank you

  • The topic ‘Change post / page status’ is closed to new replies.
Skip to toolbar