Personalization


Personalization of web sites is a powerful tool to help generate repeat visits by customizing the site layout to the preferences of individual visitors. This enables you to present to each individual user a version of the site that he or she can tailor to his or her own personal preferences.

The theory behind this process is that by allowing users to create their own "customized spaces" on your site, you make them feel more comfortable. Thus, they might decide to use your site more frequently because it feels more "familiar" to them.

You see this technique employed to great effect by almost all the large portal sites. Whether this technique actually generates increased user visitation is up for debate. However, it's still something that you're likely to see requested by those for whom you develop.

The deeper you get into discussion of personalization techniques, the more confusing it can get. For instance, you might hear someone ask about one-to-one marketing or collaborative filtering (huh?), but the bottom line is that all these techniques strive to present site visitors with a version of the site that has been specially crafted to cater to their individual needs and preferences.

Fortunately, with ColdFusion MX, creating a personalized site is as easy as treating parts of the page that you want to change from user to user as variables.

For the sake of time, we're not going to touch on the heavier aspects of personalization (like one-to-one marketing). There are many expensive software packages designed specifically to handle that type of data matching. What we can explore, however, is how to use ColdFusion to create simple personalization for even the smallest of sites.

Simple Personalization with ColdFusion

For the purposes of this example, let's assume that we have a portal type site, in which our users come in and examine news, weather, and other types of semi-static information that we hourly update from our feed.

Because our boss saw this technique used on some portal and thought it was cool, we now have to come up with a way to enable users to get a custom welcome message and to select specific subjects that they'd like to see on their "custom" versions of our page.

So, how do we do this? Well, first we have to get the information from the user. So, we create a simple form, asking the user for his or her name, password, and the three subjects in which he or she is most interested.

We store this information in a cookie so that when the user comes back to our site, we can immediately tell who he or she is and what he or she would like to see. If our bosses are unnecessarily squeamish about cookies because of some conspiracy-theorist article that they read back in 1998, we'll store all the information in a database and make the user log in to the site so that we can retrieve it.

After we have the user's first name and the three topics in which he or she is most interested, we can begin to lay out our page, as in the following example:

 <HTML>      <HEAD>      <TITLE>Our Fancy Personalization Page</TITLE>      </HEAD>      <BODY>      Hello <cfoutput>#UserFirstName#</CFOUTPUT>!      <br>      Here are the three topics you are most interested      in:<BR>      <cfoutput>      #TopicA#<BR>      #TopicB#<BR>      #TopicC#<BR>      </BODY>  </HTML> 

The previous example is about the simplest example you can imagine when it comes to personalization, but it illustrates a key point. All personalization, no matter how seemingly complex, can draw parallels to the example at which we've just looked. All you're really doing is collecting information about a user and his or her habits, and then using that information to guide him or her on your site.

In our example, we explicitly asked our user for three topics, and then we constructed a page that highlighted those three topics. However, we could have just as easily asked him or her to log in. We then could have tracked the three most-visited topics and stored this information in a database.

The next time the user comes to our site, we can automatically highlight these three topics. Keep in mind, though, that although Internet-savvy users might appreciate the technique, novices might think you're keeping too close an eye on their activities and might be scared away by this approach.

A final note on personalization: Although it might be necessary for some applications, personalization is generally used to "fluff up" sites for the user base. This is fine, but remember that it also takes server resources. Use personalization where it makes sense; but as a user, I'm not going to be too happy if it takes a page on your site an extra 10 seconds to load so that it can say "Hello Joe Schmo!"

Summary

In this section, we've examined how to use ColdFusion to create simple personalization in a web application. We've also examined some of the common uses and pitfalls of personalization in web applications.

Although some personalization might be fine to enhance the experience of visiting your site, gratuitous personalization only serves to slow down server performance, so keep this in mind when designing your applications.



Inside ColdFusion MX
Inside Coldfusion MX
ISBN: 0735713049
EAN: 2147483647
Year: 2005
Pages: 579

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net