Title: PHP Error on WP Statistics
Last modified: August 22, 2016

---

# PHP Error on WP Statistics

 *  Resolved [fehwuhi](https://wordpress.org/support/users/fehwuhi/)
 * (@fehwuhi)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/)
 * Error one:
    [http://i28.photobucket.com/albums/c216/NO2NSA/error_zpsb7568ae4.png](http://i28.photobucket.com/albums/c216/NO2NSA/error_zpsb7568ae4.png)
 * Error two:
    [http://i28.photobucket.com/albums/c216/NO2NSA/visitors_zps08f4be32.png](http://i28.photobucket.com/albums/c216/NO2NSA/visitors_zps08f4be32.png)
 * Oh also the Browsers section is also empty 🙁
 * Had this problem for awhile even before and after doing updates.
    Have no clue
   when it happened, just waited for the next update and thought it would fix it
   but still having the same error.
 * Warning: arsort() expects parameter 1 to be array, null given in /home/no2nsax3/
   public_html/blog/wp-content/plugins/wp-statistics/includes/log/log.php on line
   542
 * Warning: Invalid argument supplied for foreach() in /home/no2nsax3/public_html/
   blog/wp-content/plugins/wp-statistics/includes/log/log.php on line 545

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Contributor [Greg Ross](https://wordpress.org/support/users/gregross/)
 * (@gregross)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173174)
 * How long have you had the error for? Before 7.0?
 *  Thread Starter [fehwuhi](https://wordpress.org/support/users/fehwuhi/)
 * (@fehwuhi)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173220)
 * yes
 *  Plugin Contributor [Greg Ross](https://wordpress.org/support/users/gregross/)
 * (@gregross)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173222)
 * The errors on line 542/545 are because no visitors are being returned from the
   database to calculate the top countries.
 * Can you check your database and see how many rows are in the wp_statistics_visitor
   table?
 *  Thread Starter [fehwuhi](https://wordpress.org/support/users/fehwuhi/)
 * (@fehwuhi)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173244)
 * **I’ve did the latest update now and the only thing that has changed is the error
   previously I posted before has gone now and the boxs are just blank instead.**
 * When I go to my database and find wp_statistics_visitor and then hit the plus
   button next to it, drops down “Columns” and when I click on that database It 
   shows me…
 * **Space usage
    Data Total 0B
 * **Row statistics
    Rows 0
 * When I click onto database wp_statistics_visitor I get this error.
    ** #145 –
   Table ‘./no2nsax3_no2nsa/wp_statistics_visitor’ is marked as crashed and should
   be repaired
 * The sidebar of my website has the widget appearing and it is showing this Information
   about my website and the visitors.
 * **User Online: 1
    Today Visit: 68 Yesterday Visit: 528 Week Visit: 6920 Month
   Visit: 18783 Years Visit: 97593 Total Visit: 97593 Total Posts: 656 Total Users:
   97 Average Posts: 4.37 Average Users: 0.65 Last Post Date: Aug 8, 2014
 *  Thread Starter [fehwuhi](https://wordpress.org/support/users/fehwuhi/)
 * (@fehwuhi)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173246)
 * This is fixed now, sorry about that!
 * Had to do database repair and now everything is working 🙂
 *  Plugin Contributor [Greg Ross](https://wordpress.org/support/users/gregross/)
 * (@gregross)
 * [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173248)
 * Ok, no problem.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘PHP Error on WP Statistics’ is closed to new replies.

 * ![](https://ps.w.org/wp-statistics/assets/icon.svg?rev=3081064)
 * [WP Statistics – Simple, privacy-friendly Google Analytics alternative](https://wordpress.org/plugins/wp-statistics/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-statistics/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-statistics/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-statistics/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-statistics/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-statistics/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [Greg Ross](https://wordpress.org/support/users/gregross/)
 * Last activity: [11 years, 10 months ago](https://wordpress.org/support/topic/php-error-on-wp-statistics/#post-5173248)
 * Status: resolved