HomePHP Developing a User Personalization System with PHP and Cookies
Developing a User Personalization System with PHP and Cookies
Making your site more appealing to repeat traffic is always a priority among web developers. However users of your site are likely to be coming to your site for different reasons. This tutorial will teach you how to use PHP and cookies to make your site more user-customizable and therefore more likely to attract repeat users.
Everyone is looking for ways to make their sites attract more repeat traffic. Even after you have content, bulletin boards and search functions, there's still more you can do. As you probably know, different people that come to your site probably come for different parts of your site, but there's no way to please everyone, is there?
In this example, we will take some headlines from a couple of sites some people may visit often, then make a form to collect logins and preferences, and store it all in a database. Every time the user returns, a script reads their cookie, retrieves their preferences, and builds a page showing what they want to see. We'll start out with a smattering of Perl to help us automate collecting those headlines.