Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Damon 217 posts 287 karma points
    Jul 23, 2015 @ 08:49
    Damon
    1

    Can a list of most viewed page be retrieved using this package?

    Hi,

    can this package simply provide a list of most viewed pages so they can be built into a navigation menu?

    Thanks,

  • Warren Buckley 2106 posts 4836 karma points MVP ∞ admin hq c-trib
    Jul 23, 2015 @ 14:32
    Warren Buckley
    0

    Hello Damon,
    There is nothing built in currently to allow this.

    However with the package installed you could in theory create a new method in a controller or WebAPI controller depending on how you see yourself implementing this, using the same/similar code I use to display the results in the section.

    https://github.com/warrenbuckley/Analytics/blob/develop/Analytics/Controllers/AnalyticsApiController.cs#L96

    You can see the method in the WebAPI controller here for a pointer. This would give you most page views. You would need to modify the request for the date range you wish and to use the object to loop over the results in a partial razor view for your navigation or whatever you wish to do with these results in your front end of your site.

Please Sign in or register to post replies

Write your reply to:

Draft