WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] [Plugin: CyStats] Warning displayed in blog after upgrading to WP 2.6 (10 posts)

  1. sairuh
    Member
    Posted 5 years ago #

    Hello,

    After I had upgraded to WordPress 2.6, I went to view my site stats on the CyStats page. Strangely, after I had done that (and I didn't make any changes to my settings in CyStats), the following warning was displayed on every blog page, even when I was logged out:

    Warning: unserialize() expects parameter 1 to be string, array given in [my-path]/wp-content/plugins/cystats/includes/cystats.class.php on line 97

    [my-path] refers to my WP installation directory.

    Why is this occurring? Could this be a bug in CyStats?

    http://wordpress.org/extend/plugins/cystats/

  2. sairuh
    Member
    Posted 5 years ago #

    Thanks for the 0.9.1 update! While I no longer get the warning I posted earlier, unfortunately another warning is displayed:

    Warning: array_map() [function.array-map]: Argument #2 should be an array in [my-path]/wp-content/plugins/cystats/includes/cystats.class.php on line 99

    Let me know if there's anything on my end I could do to work around this.

  3. cywhale
    Member
    Posted 5 years ago #

    Do you use one or more user agents to ignore (options panel)? This bug drives me crazy, everything is working fine here... hrm.

  4. sairuh
    Member
    Posted 5 years ago #

    This is what I have in the Ignore User Agent textarea:

    <br />
    <b>Warning</b>:  array_map() [<a href='function.array-map'>function.array-map</a>]: Argument #2 should be an array in <b>[my-path]/wp-content/plugins/cystats/admin/options.php</b> on line <b>166</b><br />
    <br />
    <b>Warning</b>:  implode() [<a href='function.implode'>function.implode</a>]: Invalid arguments passed in <b>[my-path]/wp-content/plugins/cystats/admin/options.php</b> on line <b>166</b><br />

    That looks odd, since it looks like HTML rather than a regular expression! Should I remove it?

    Btw, I do block three IP addresses to ignore, but I don't know if that's relevant. Let me know if you need to know about other settings I use.

  5. cywhale
    Member
    Posted 5 years ago #

    There is something terribly wrong with cystats code and serializing arrays in WP 2.6 options. I had to remove those option fields for ignoring agents, ips and page ids. Uploaded this *workaround-version as 0.9.2 right now. Sorry for that.

  6. cywhale
    Member
    Posted 5 years ago #

    This issue should be sloved for WordPress 2.6+ with CyStats 0.9.4.
    From this version on CyStats should be used only with WordPress 2.6+, the handling of serialized arrays in wp_options seems to have changed somwhere between 2.5 and 2.6.

    Please report any problems with CyStats 0.9.4 and WordPress 2.6+

  7. sairuh
    Member
    Posted 5 years ago #

    CyStats 0.9.4 now works with WP 2.6. No more warnings display, and I can modify the Ignore IP Addresses options as well.

    Thanks for fixing this! Marking this thread as resolved.

  8. AngryBrownGuy
    Member
    Posted 5 years ago #

    Warning: array_map() [function.array-map]: Argument #2 should be an array in [my-path]/wp-content/plugins/cystats/includes/cystats.class.php on line 99
    
    Warning: array_map() [function.array-map]: Argument #2 should be an array in [my-path]/wp-content/plugins/cystats/includes/cystats.class.php on line 100
    
    Warning: Invalid argument supplied for foreach() in [my-path]/wp-content/plugins/cystats/includes/cystats.class.php on line 1333

    even after installing the new update, I'm still getting the above code displayed on my site. if you want to take a look, any suggestions?

  9. cywhale
    Member
    Posted 5 years ago #

    Which WordPress version do you use? In WP 2.6.1 serializing behaviour seems to have changed again and some errors occur again, bugfix releas of cystats should be online within the next 12 hours.

  10. AngryBrownGuy
    Member
    Posted 5 years ago #

    I have 2.6.1 and after completely removing the plugin and uploading it again, it has removed the code off the page for now. hopefully it stays that way.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags