Asked

how to implement number of views for each item detail page?

Google analytics vs. keeping track of total views for each item detail page. What is the best way to track?

Bot Stash, Producthuntian
fuck facebook

What stack are you working with?

Bot Stash, Producthuntian

Java, Spring MVC, Hibernate

http://twitter.com/quangv

If I understand your problem, seems like you have to manually trigger/fire a "view", after a dynamic page change on your site?

Decentralization evangelist, Entrepreneur, Life hacker, Backend engineer. Cyberpunk @ Woodpckr.com | Building AirGapped Crypto Vault live on stream

GA is fine. Use their api to pull info periodically cache it.

If you implement something custom, make sure its JS based and not done while generating the page to server things.
With html cache, you fail to record metrics. Without it, even typing url on chrome, would register 2 hits cuz chrome fires request right away before typing to urls that might be what you want, before you select one suggestion or hit enter.

Bot Stash, Producthuntian

You are correct. I found out GA is doing all this. so data gathering becomes easy. The next thing is retrieving those data from GA. So are you seeing pull this data from GA and store them in database and get updates from GA periodically?

Decentralization evangelist, Entrepreneur, Life hacker, Backend engineer. Cyberpunk @ Woodpckr.com | Building AirGapped Crypto Vault live on stream

Yes! WordPress even has a plugin for it but I had to fix an issue in it to make it work for my client. This was sometime last year.

Bot Stash, Producthuntian

Thank you buddy. I will try it.

Bot Stash, Producthuntian

You are correct. I found out GA is doing all this. so data gathering becomes easy. The next thing is retrieving those data from GA. So are you seeing pull this data from GA and store them in database and get updates from GA periodically?