Sign in

E-mail *, (xx@domain.com)
Password *

Register | Forgot password

Recent blogs

RSS - Blogs
December 24, 2008
The year has almost ended...
December 9, 2008
5 Spring pitfalls
December 9, 2008
Like A Version
October 22, 2008
New certification process
October 17, 2008
Search quest [3/3] - improvements

All Blogs...


New in WebManager 9.5 part 2: Personalization API

July 16, 2008

GX WebManager 9.5 was released a few days ago and I will write some blog posts to elaborate a bit more on the new features for developers in 9.5. So you’ll not only hear our marketing department say how cool every feature is, but also see that things actually work.

In this blog post more about another new feature: the personalization API. We already have many kinds of APIs for various parts of our CMS, but until now we didn’t have a way to read or write personalization expressions and models.

The basics: GX WebManager and personalization

For developers who never used personalization in WebManager I will give a very short overview. Personalization in GX WebManager is done by 2 things: 1) a user session that contains information about the user (and all sorts of other stuff) and 2) transformations and logic applied to the content. Nr 1 is done with XML: the entire user session is stored and available in XML format. Nr 2 is done with - how surprising – XSLT. So in a nutshell: you can accomplish personalization by applying XSL transformations to an XML user session.

A Quick example

Say I created a site and added the webuser forms add-on. I can then create a user, edit my details and login to the website. I can view my session which will show something like:

XML session XML session

Now I’d like to use this information to show an image on a page depending on the user’s age. For example the image has to be showed when the visitor is younger than 50. To do this I create a personalization expression like this:

substring(/root/system/user/birthdate,1,4) >  (substring(/root/system/date,1,4)-50) 
 
 

This XSLT compares the year of birth of the user with the current year minus 50. This expression will result in either a TRUE or a FALSE, which determines if the image is shown or not. Application managers can define custom personalization expressions and any editor can apply personalization to the image simply by choosing from a list of personalization expressions:

Personalization experssions Personalization experssions


Ps: the little red ‘person’ icon in the top right corner of the image element shows that the image is personalized.

Result of this example: there is an image that is only shown when the visitor is younger than 50.

Combine personalization expressions into personalization models

When you have various personalization expressions you can combine them to create target groups for example, which is often the case in marketing campaigns. Suppose you have 3 banners for new mobile phones, one for women, one for men younger than 50 and one for men above 50. You need 4 expressions:

  1. check if the user is female
  2. check if the user is male
  3. check if the user is younger than 50
  4. check if the user is older than 50

You combine male + younger than 50 into a model called ‘males younger than 50’ and also create a model ‘males younger than 50’. When you apply this you can create something like this:

Personalization applied Personalization applied

Technology

The strong point of personalization in GX WebManager is that it provides personalization to the editors and marketeers of a website, instead of having to rely on (hard)coded personalization. Most of our competitors can’t say the same. CMS’es on other platforms such as PHP can’t offer the same mechanism because PHP simply isn’t capable of doing this on a large scale. Java with its layered architecture and its filters can offer XSL transformation simply as a layer, whereas in PHP you have to integrate this into your normal template rendering. Did I mention we love Java? :- )

On topic: New in 9.5…

Any of the above has been available in GX WebManager for at least 3 years. So what’s new? New is the fact that you can read and write all the personalization expressions, models and values from Java or JSPs. The number one reason to do this is to be able to do this in (custom) WCBs. I will give you some examples that show what you can do with this.

Example: Create a metadata WCB with personalization models

Suppose you set up a marketing campaign to promote the new iPhone in your online shop. You want to report additional information to your web analytics tool and to your affiliate partners, but only for the shopping and promotion pages and not for the entire website. Plus  you don’t want to change any code in templates.

 In WebManager you can create a so called ‘page metadata WCB’ that adds extra options for metadata or webservices to pages. The personalization API can be used to create a dropdown menu with all personalization expressions that can be added to the page. Once an expression is added to a page it’s logged and sent to your affiliate partner(s). For the iPhone campaign you might want to know more about the user’s sex, browser agent and order history, so you easily select these options:


Because you only select these options for several pages you don’t send unnecessary data to your log files. Without the personalization API this would not be possible because the personalization expressions and models could not be retrieved.

Other applications

The personalization API will most likely be used in situations as the one above where WCBs in the form of elements, metadata or form handlers can be used to get() or set() personalization expressions and models.  You can also use the personalization API to apply personalization to imported content. This gives more freedom to combine logic with personalization and apply this where necessary.

When you look at the simple examples above and think a minute about what you can do with this then you hopefully realize that the possibilities are endless. Especially given the fact that a lot of information is stored in the user session and that during a user’s visit you can add information, also for anonymous visitors. This opens the door for exciting new applications such as behavioral targeting, multi variant testing based on personalization, targeted campaigns, targeted affiliate marketing etc. GX WebManager now has all the APIs and tools to read and write to sessions so you can do whatever you want.  I’d love to hear and see what you are building!

 

About the Author

Return to all blogs


Martin van Mierloo is Product Manager and has many years of experience with GX WebManager. Martin writes about the GX WebManager roadmap, new product features and WCMS related topics..
Read all Martins blog entries

Other blog entries:

December 24, 2008
The year has almost ended...
October 22, 2008
New certification process
October 17, 2008
Search quest [3/3] - improvements
October 17, 2008
New in 9.6: Import/export
September 17, 2008
Using Google Custom Search on your site
July 10, 2008
New in WebManager 9.5 part 1: Content API additions
June 27, 2008
Ease of implementation
June 18, 2008
Content Management and Sustainability
May 28, 2008
Search quest [2/3] - Relevance
March 13, 2008
Search quest [1/3]


Share:

del.icio.us
digg
Technorati
Slashdot
Reddit
YahooMyWeb
NewsVine
ekudos
© 2008 GX creative online development B.V.

Disclaimer

This website (GXdeveloperweb.com) may discuss or contain opinions, (sample) coding, software or other information that does not include GX official interfaces, instructions or guidelines and therefore is not supported by GX. Changes made based on this information are not supported.  GX will not be held liable for any damages caused by using or misusing the information, software, instructions, code or methods suggested on this website, and anyone using these methods does so at his/her own risk. GX offers no guarantees and assumes no responsibility or liability of any type with respect to the content of this website, including any liability resulting from incompatibility between the content of this website and the materials and services offered by GX. By using this website you will not hold, or seek to hold, GX responsible or liable with respect to the content of this website.