Cookies or session to use in this case?

Want to make a widget "You watched" and put last viewed by the user of the goods or services. Put the info in a cookie or in session?
July 8th 19 at 11:54
4 answers
July 8th 19 at 11:56
in cookies of course IMHO... because there is nothing to fake ))))) just info and nothing more
July 8th 19 at 11:58
Inclined to think that the sessions need to store something important and valuable, and cookie all the rest :)
Cookie can be easily edited, and with sessions is to do the impossible.
July 8th 19 at 12:00
Do the knight: save the session in a cookie, and the data "have you seen" in the session.
)) - Kendrick_Schu commented on July 8th 19 at 12:03
: I'm not kidding. - glennie_Mer commented on July 8th 19 at 12:06
July 8th 19 at 12:02
1. Better to store in the cookie is the user not even just "views" but also "the basket" (ID only-items and their number; calculation of prices - ONLY through the server session).
2. If You need information on the server - record it when the page is requested and when you add a product to the cart on the server side in the session.

Find more questions by tags HTTP CookiesSessionsPHP