Support » Plugin: Post Expirator » Expirator

  • I find Post/Page Expirator very useful but hope someone can help please.

    When a post is sent to DRAFT from Post Expirator it remains on the home page as a latest post although it returns the post as a query it has removed all links thus returning a 404 error if selected.

    Is it possible to remove the post from latest posts so that it does not show as a post to be selected, at the same time as Post Expirator moves the post to draft.

    Any help really appreciated.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Hey Clife, that means that your latest post query is also pulling drafts. You need to modify the query so it only pulls published posts. If you can’t modify the query, then you will have to set the post expirator to move the posts to trash instead of draft.

    
    $query = new WP_Query( array(
        'post_status'   => 'plublish',
    ) );
    
Viewing 1 replies (of 1 total)
  • The topic ‘Expirator’ is closed to new replies.