Hi there!
WPP updates the views count via AJAX. For some reason, while making the request your server returns a 403 Forbidden error message (see screenshot).
Thanks for the quick reply, definitely helps steer us in the right direction. I suspect in both cases (ajax or non-ajax) the plugin would need access to a file within the “/admin/” directory?
I think for security reasons this gets blocked on the current site and suspect this could be the culprit… which we might not have a work around for, so I’m curious if there is anything we can do on the plugin’s side.
Let me know! Thanks
I suspect in both cases (ajax or non-ajax) the plugin would need access to a file within the “/admin/” directory?
Indeed, the plugin needs access to /wp-admin/admin-ajax.php to update the views count. Same goes for the Ajaxify widget feature – won’t work without it.
… I’m curious if there is anything we can do on the plugin’s side.
Unfortunately no – unless you’re willing to change the way WPP sends data to the DB.
Prior to 3.x.x, older versions of the plugin would update the views count as soon as the_content action was triggered (see relevant part of the code here, that’s v2.3.7). While that worked, it also allowed bots and web crawlers to bloat the views count. To prevent that from happening, I rewrote that part of the code to use Ajax instead since most bots out there can’t/don’t need to parse and execute Javascript code.
You could try porting back that functionality to the current version of the plugin -it shouldn’t be too difficult- but you’d also have to keep patching the code every time WPP gets updated. Alternatively, you could also downgrade to version 2.3.7 but I really don’t recommend that: you’d lose over 2+ years (at the time of writing) of bug fixes, enhancements and new features. And let’s not forget about the bots-inflating-your-views-count part 😛
Hello,
I’m having the same problem. No Daily views, 7 days or 30 days only All Time.
Are you saying that there is no fix for these? I think this started to happen when I updated the WP to 4.3.
Thanks
Yours might be a completely different case, @meiocheio. You’ll have to provide further info to get some help, otherwise there’s nothing much I can do with so little details from your part.
Thank you for your reply.
I have the plugin installed for over a month and it was working until a few days ago.
I have WordPress 4.3
Just updated the plugin to 3.3.0
While I was writing this message, I went to check if the plugin was running after the last update and I think it is working properly.
Thank for your support and for this great plugin.
Best Regards
Alright then, please let me know if anything changes in that regard 🙂
Hey @rms898s, were you able to resolve the issue? Do you still need a hand with this?
Hey Hector – thanks for following up – unfortunately they run a pretty tight ship security wise so we won’t have access to /admin/ publicly… and I’m not sure it makes sense for us to have to manually maintain the plugin per your suggestion of downgrading, etc
I think we’re currently looking for alternative solutions 🙁 …but we def. appreciate your help so far!
I figured as much but had to ask anyways. If you need further help please let me know.