D
D
Dmitry Klimantovich2021-03-12 16:07:34
1C-Bitrix
Dmitry Klimantovich, 2021-03-12 16:07:34

How to display items randomly once per session?

Good afternoon.

How to display the elements of the news.list component randomly once per session? Setting the RAND value in the field for the first sort or in the sort direction is not suitable - because of this, when you go to the next page of the list, the results are shuffled again.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander, 2021-03-12
@idruweb

cache once a day

V
Vitaliy Vayti, 2021-03-23
@vitvayti

You can pass any key to the component parameters, as an option, you can add an arbitrary parameter and pass the session ID to it and cache it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question