Bookstack: [Question] Users analytics?

Created on 5 Nov 2019  路  5Comments  路  Source: BookStackApp/BookStack

Hello,

Quick question here, is there any users analytics (views, page created, etc) in the current release?
Thanks :)

Question

All 5 comments

Hi @lewildfox,
Nothing major in the system right now, focused on analytics.
There is a user-profile page that contains some very light stats.

On the database side, General activity such as creation, updates & deletions are recorded in the database along with user & entity (Book,Page,Chapter,Shelf) ids. View actions are also recorded, aggregated per-user, per-entity which I think also includes a last-viewed date.

So no interface right now (Has been requested and would be nice but complex to suit everyones needs and low priority in terms of development) but if you extract info from the database or hook an analytics suite/business intelligence tool to the database you'll likely be able to report on quite a lot.

Hi @ssddanbrown ,

Is there a way to add a script to every page instead?
Google Analytics requires that you a something like the script below to every page you want to track.
`

`
If one is just starting up, I'm guessing it can be added per page using HTML
However for a site already couple of hundreds of pages, it going to be too much waste of time editing each page. If we can be provided with a way to add a global script that is applied to every page, that would be great. At least for Google Analytics users.

Thanks

Hi @openmoto,

Google Analytics scripts can be placed in the Custom HTML Head Content /settings#setting-app-custom-head portion of your BookStack settings. Although user data cannot be added dynamically to the gtag, it will allow you to include Google Analytics on every page.

Per-user data, as @ssddanbrown mentioned, is aggregated in the database.

I utilize a combination of these methods for my analytics.

Hope this helps!

Yeah, spot on @james-geiger, The Custom HTML head content setting is ideal for that kind of thing.

Although user data cannot be added dynamically to the gtag

You could cheekily load the gtag script on DOMContentLoaded, Grab the user's ID from their profile link in the header bar, then send that off with the gtag events if you really need to tie up GA data to users; Obviously not an official way of doing things :smile:

Since the original question was answered I'll close this.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tpetrauskas picture tpetrauskas  路  4Comments

Legoracers picture Legoracers  路  3Comments

gab-cass picture gab-cass  路  3Comments

hhk7734 picture hhk7734  路  3Comments

ensemblebd picture ensemblebd  路  3Comments