Here is a sample code to show how using php and cookie to tracking the user's browsing history. The code is used on a shopping website.
Hope it helpful to you.
Thank you for taking the time to visit my blog! Take a second to peek around and check out some of my previous posts. Of course, I would love to find out what you think as well, so make sure to comment. See you around!