Successful install-
I use Piwik so I guess I can't use it yet, but this is a useful plugin!

16 days later

Installed but doesnt appear on Extensions List?

    Red that's very little to base any advice on. Can you elaborate? Does the directory exist under extensions?

    i used composer to install extension and its under vendor/hyn directory not in Extensions
    .

      Fixed, Thank you.

      15 days later

      I installed this plugin and it works. But somehow it seems only to fire a pageview at the load of the forum front page. When I click a post, it doesn't seem to fire a pageview. I'm not sure if this is because the plugin is built like that or I did something wrong.
      I know Flarum actually doesn't load a new page when navigating the forum since everything loads with ajax, but to use Analytics effectively, we need a faux pageview to be fired at the click of a post and at the click of a category. I guess this can be done easily by firing a pageview each time the URL changes.
      Thanks again for providing this extension. I hope you can use the feedback.

        Jahman that is something I never considered. I will look into it asap, thanks for pointing that out.

          Jahman we need a faux pageview to be fired at the click of a post and at the click of a category. I guess this can be done easily by firing a pageview each time the URL changes.

          The url actually also changes when scrolling. I think I can handle this by listenening to a m.redraw() event, not sure that's even possible though, will look into it.

          Jahman

          Version 0.2.1 released, might need to re-enable after updating with composer to dump caches. Tested locally with console.logging and does hit.

          Red weird composer acting strange again. Use dev-master otherwise. I'll fix it asap.

          Red Fixed it, forgot to remove version from the composer file.

          • Red likes this.
          14 days later

          I had a small problem with hyn/flarum-analytics, but it has been fixed, so I delete my posts on the subject, they are no longer meaningful.

            Averell Sounds like a cache issue. After adding the extension to composer you might have needed to delete the assets/*.js files. Or enable and disable the extension via the admin.

            Any errors in the console or in your logs?

            luceos changed the title to hyn/analytics ; google analytics website statistics .

            Averell Did you try deleting everything under storage/views/?

            It seems the remote include has not happened. I committed a fix that will prevent the error in the future.