Forums

[resolved] post_status (4 posts)

  1. smartidu
    Member
    Posted 2 months ago #

    I was looking at the wordpress tables and in wp_posts table I found that there are 3 type of post status,

    - publish
    - inherit
    - revision
    - any more??

    I was wondering what's the difference among these and how wordpress determines which one to show when a post/blog is viewed? For the same post, I found there are multiple versions with types publish, revision and inherit.

    I was trying to create an extension but need to know how this works so I can pull the correct/latest post uniquely.

  2. MichaelH
    moderator
    Posted 2 months ago #

    Post status:
    publish - A published post or page
    inherit - a revision
    pending - post is pending review
    private - a private post
    future - a post to publish in the future
    draft - a post in draft status
    trash - post is in trashbin (available with 2.9)

    So post_status of 'publish' and post_type of 'post' for your query.

    Review:
    query_posts()

  3. smartidu
    Member
    Posted 2 months ago #

    Thanks for your help!

  4. haikuotiankong
    Member
    Posted 1 month ago #

    thanks

Reply

You must log in to post.

About this Topic