N
N
Nikita Dergachov2016-12-10 19:53:13
Sessions
Nikita Dergachov, 2016-12-10 19:53:13

How to display the top most visited pages of the site?

There is a site written in laravel, how to display the top most visited pages of the site?

Answer the question

In order to leave comments, you need to log in

5 answer(s)
M
Mikhail Osher, 2016-12-10
@miraage

middleware.

M
Mouvdy, 2016-12-10
@Mouvdy

You can generally parse webstat if it is enabled

A
Alex Wells, 2016-12-11
@Alex_Wells

pseudo code:
after middleware
$response = $next($request);
add task "newPageView" to queue
return
newPageView class
check if url is correct
push data to file/database

D
Dmitry Gadzhiev, 2016-12-10
@gds1

In the database, make a cell in which the number of visits will be recorded. Then make a selection according to the TOP most visited.

K
KostyaNV, 2016-12-12
@KostyaNV

via Request::url get and add the number of visits in the database

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question