WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: Sociable] Warning- array slice() message on dashboard (3 posts)

  1. jacklenk
    Member
    Posted 5 years ago #

    I just installed Yoast on WP 2.7.0 with Modularity theme from Graph Paper Press. It seems to work okay in the posts but on my WP Dashboard I get this message in the Yoast box:

    Warning: array_slice() expects parameter 1 to be array, null given in /data/13/0/5/86/5249/user/5360/htdocs/home/wp-content/plugins/sociable/yoast-posts.php on line 43
    - No items

    Any ideas? Please advise.
    Thanks,
    Jack

  2. cobaltwolf
    Member
    Posted 5 years ago #

    No problems under WP 2.7. However, I started getting a similar message after I upgraded my local copy of WordPress to 2.7.1 (I always test WP locally before doing any updates on my live site):

    Warning: array_slice() expects parameter 1 to be array, null given in D:\xampp\htdocs\clubda\wp-content\plugins\sociable\yoast-posts.php on line 43
    No items

    From what I could see, lines 42-43 of yoast-posts.php deal with fetching rss feeds from feeds.feedburner.com/joostdevalk. Should I worry about this or would it be OK to update my live site to 2.7.1?

  3. stanilund
    Member
    Posted 5 years ago #

    Could there be something wrong in rss.php in the includes dir, in the function fetch_rss(url)? The function does not return anything! Made some testing:`include_once(ABSPATH . WPINC . '/rss.php');
    $rss = fetch_rss('http://feeds.feedburner.com/joostdevalk');
    if ($rss == '') {
    echo '

  4. Flödet är tomt
  5. ';
    }else if ($rss == 0){
    echo '
  6. Flödet är noll
  7. ';

    }else{
    $items = array_slice($rss->items, 0, 2);
    }
    `
    The url is correct - it works when I paste it into my beowser.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags