Take the community feedback survey now.


Aug 1, 2011
  4827
(0 votes)

Weather Criterion

Apparently British people talk about weather a lot. So wouldn’t it be good to personalise the content based on the weather of the visitor’s location?  Your site visitor had a bad day before visiting your site, and found out that at least it is still sunny outside and he can go to the beach with the family after work Smile

The Custom Criterion uses Google Weather API and expect the user profile to have a ZipCode property. If you are trying it on the Alloy Tech site, set up the workroom component, and locate the file ~/templates/AlloyTech/Units/Placeable/PersonalSettings.ascx. You can easily modify the code to set/get user’s ZipCode information.

A typical zip code in UK, Sweden and USA is such as

  • EC1N 8SS
  • 103 86, Stockholm
  • 60181

Very quick and dirty project as part of my new exposure to EPiServer personalisation. Now you have the source code so let’s see your imaginations!

See the code: Download

.
Aug 01, 2011

Comments

Please login to comment.
Latest blogs
Introducing the OMVP Strategy Roundtable: Our First Episode Is Live

One of our biggest priorities this year was strengthening the strategic voice within the OMVP community. While the group has always been rich with...

Satata Satez | Dec 1, 2025

Optimizely CMS - Learning by Doing: EP08 - Integrating UI : Demo

  Episode 8  is Live!! The latest installment of my  Learning by Doing: Build Series  on  Optimizely CMS 12  is now available on YouTube! This vide...

Ratish | Dec 1, 2025 |

Migrating Optimizely 11 to 12: SQL Membership & Legacy Hashes (Part 2)

In [Part 1] , we handled the migration of users who were already using ASP.NET Identity. Now, we tackle the more complex scenario: the MembershipUs...

Amit Mittal | Dec 1, 2025

Migrating Optimizely 11 to 12: Handling Legacy Password Hashes (Part 1)

Recently, I was tasked with a complex migration: moving existing users from two Optimizely 11 projects to the new Optimizely 12 (ASP.NET Core). The...

Amit Mittal | Dec 1, 2025