• bobcooper

    (@bobcooper)


    Hi there,

    I am using AMFPHP to get my blog posts from the database so that I can then get at the info from inside flash. It’s all working fine, but the problem is the order… When I look at wp_posts.post_title the order is very strange, and some of my posts are repeated.

    I am assuming this has something to do with having multiple categories for each post so they get duplicated.

    I was wondering how wordpress organises the posts so that they display in the right order, am I using the correct tables?

    Thanks,

    Bob
    [sig moderated – read the rules]

Viewing 1 replies (of 1 total)
  • MichaelH

    (@michaelh)

    A valid post has, in wp_posts, a post_type of ‘post’ and a post_status of ‘publish’. A draft post has a post_type of ‘draft’.

    A post revision has, in wp_posts, a post_type of ‘revision’ and a post_status of ‘inherit’. A revision is a ‘previous’ copy of a post. There could be many revisions of the same post.

    A valid page has a post_type of ‘page’ and a post_status of ‘publish’. A draft page has a post_type of ‘draft’.

    An attachment to a post/page has a post_type of ‘attachment’.

    As a note, a post with 15 categories or tags will have but one record (assuming no revisions) in wp_posts, but will have 15 entries in the wp_term_relationships table.

Viewing 1 replies (of 1 total)
  • The topic ‘How is the table wp_posts structured?’ is closed to new replies.