I got a page that lists videos in an index view. The view is filterable by several indicators, like 'newest videos first' and 'highest ranked videos first'. The user can choose from one of these options.
The filter information is stored in the users session. To control the session parameters, there are different routes, that get called when the user clicks a filter button, like "domain.com/videos/newest" or "domain.com/videos/ranking".
Dependent on which route gets called the server alters the session parameter.
In fact the SAME page is rendered but videos are listed in different orders. This leads to duplicate Page Titles, Meta descriptions and things like that. This should be avoided. I want to have one route "domain.com/videos" without additional filter control parameters.
Obviously there are different approaches:
Sticking with the current solution, providing different routes, that are leading to the same rendered page, and deal with duplicate content.
Using GET Parameters like
domain.com/videos?filter=newest, which is not good from a SEO perspective as well.Using Cookies to store the information in each Requestheader, which leads me to the need of a Cookie Agreement message and makes the page experience ugly.
...
Are there recommendations to deal with the described problem?
UPDATE
@Tim Lewis suggested (thank you very much for the replie):
If you don't want URL parameters, you can do a POST request that stores these filter/search/sort values in Laravel's session, then reference them in the GET request; $sort = session()->get("sort"); or similar. They wouldn't show up in the URL, and the only page SEO would be aware of would be domain.com/videos
Are there more people that go confirm with that ?
POSTrequest that stores these filter/search/sort values in Laravel's session, then reference them in theGETrequest;$sort = session()->get("sort");or similar. They wouldn't show up in the URL, and the only page SEO would be aware of would bedomain.com/videos