WordPress.org

Forums

WP RSS Aggregator
Date-related Error from feed (3 posts)

  1. nikosv
    Member
    Posted 1 year ago #

    I am getting the following error from a feed:

    Warning: date() expects parameter 2 to be long, string given in /home/logica/public_html/wp-content/plugins/wp-rss-aggregator/includes/admin-display.php on line 116

    can i fix that somehow?

    http://wordpress.org/extend/plugins/wp-rss-aggregator/

  2. nikosv
    Member
    Posted 1 year ago #

    And here is the format in the xml

    <pubDate>Fri, 19 Apr 2013 10:20:56 +0300</pubDate>

    I tried fixing the error by changing the code into

    case "publishdate":
    		$pub_date = get_post_meta( get_the_ID(), 'wprss_item_date', true );
    		if(is_string($pub_date)){
    			$pub_date = (int) $pub_date;
    		}
                    $publishdate = date( 'Y-m-d H:i:s', $pub_date) ;
                    echo $publishdate;
                    break;

    However while there is no error anymore, the echoed date is always 1970-01-01 00:00:00 which probably due to the unexpected format of the rss date.

  3. Jean Galea
    Member
    Plugin Author

    Posted 1 year ago #

    Hmm I have no quick fix, will have to look into it more closely.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP RSS Aggregator
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.