• Resolved Niels Pilon

    (@nielspilon)


    I’m currently testing your plugin with three agenda feeds that all have posts with a publish date in the future. All these items are visible in the ‘Feed list’ but are not visible on the page that holds the shortcode. It shows an error instead: No feed items found.

    Aren’t these items not displayed because they are scheduled or is it because I haven’t installed the MySQLi extension on our server? Because that’s the error that I see in the ‘Debugging’ tab. I’m also getting an ‘The feed URL is not valid! Please recheck:‘ error while all three feeds are validated and all items in these feeds are shown in the ‘Feed list’.

    Thanks in advance.

    https://www.ads-software.com/plugins/wp-rss-aggregator/

Viewing 2 replies - 1 through 2 (of 2 total)
  • That’s right, posts with a date in the future aren’t displayed by default since WordPress forces them to a “future” post status rather than “published.” You can get around this by using the following filter:

    <?php
    add_filter( 'wprss_display_feed_items_query', 'my_show_future_posts', 10, 2 );
    function my_show_future_posts( $args, $settings ) {
        // $args['order'] = 'ASC'; // Reverses the sort order
        $args['post_status'] = array('publish', 'future');
    
        return $args;
    }
    ?>
    Thread Starter Niels Pilon

    (@nielspilon)

    Works great, thanks a lot!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Show scheduled posts in the feed’ is closed to new replies.