Perlkonig / grav-plugin-count-views

Simple and naive page view counter for Grav CMS
https://www.perlkonig.com/demos/count-views
MIT License
3 stars 2 forks source link

page counts overwritten #1

Closed andrewd72 closed 7 years ago

andrewd72 commented 8 years ago

I'm not 100% sure how it is supposed to work but at the moment /user/data/count-views.yaml is only recording the last viewed page, not a record of all the page views. Thanks.

Perlkonig commented 8 years ago

You should be seeing something like the following (from my YAML file):

/: 507
/blog/tripwire-by-lee-child: 3
/demos: 32
/blog/die-trying-by-lee-child: 3
/blog/panic-virus-by-seth-mnookin: 3
/blog/recipes-bread-week: 1
andrewd72 commented 8 years ago

I only ever get one line so the count is max 1. e.g. /blog/mypage/: 1 then if I go to a different page it gets replaced rather than appending the new line.

andrewd72 commented 8 years ago

It IS working on my remote server! That is on php7, localhost is on php 5.6.25, I think that is the only difference between them.

Perlkonig commented 8 years ago

Hrm. I don't know enough about the differences to know if that's a possible cause.

Perlkonig commented 7 years ago

Did you ever figure this out? I'd need a copy of your user folder to replicate.