I am developing an online course website based on WordPress.
Each course has audio file only so I am using an audio player to play the courses (no video).
Assume website has 10 courses with names A, B, C, D, E, F, G, H, I, and J.
Users can listen to the first half of each course for FREE (no login is needed).
For logged-in users, I save "user's last position per each course" in database.
I am trying to track last position for logged-out users using "persistent-cookies".
However, I encounter the following issue as described below:
A logged-in user named "Mike" starts to listen to the following courses:
- Course A - Stops after 1 minutes.
- Course B - Stops after 2 minutes.
- Course C - Stops after 3 minutes.
The above last positions are kept in database.
The next day, Mike visits website again but he is logged out.
Mike then listens to the same courses as follows:
- Course A - Stops after 4 minutes.
- Course B - Stops after 5 minutes.
- Course C - Stops after 6 minutes.
Then, Mike is logging into the website using username/password.
Here is my question:
After Mike logs-in,
should I show Mike last positions stored in DB (1 min, 2 min, 3 min) OR
should I show Mike last positions stored in cookies (4 min, 5 min, 6 min)?
NOTE: we would like to give our users a free preview of each course without requiring users to login first.