November Happy Hour will be moved to Thursday December 5th.

Per Nergård
Mar 24, 2014
  2818
(1 votes)

FPWC and blocks

A while ago I needed to implement a module that simplified should find pages, where a certain person was set as responsible, and do stuff to them. A responsible person corresponds to a page reference value stored in a localblock page reference property on each page.

Ok never tried FPWC with blocks so I Googled and found Alf Nilsson’s excellent post on the subject. Seemed simple enough so I went on and implemented the module but when I started to test it I couldn’t get it to work. 

I quickly narrowed it down to the FPWC call which for some reason didn’t return any hits. At first I thought I hade done some simple typo error when creating the criteria but no.

After a bit to much time debugging I found out that the problem was that the page reference property I was searching for was placed in a block.

I reported it to the support which first confirmed it as a bug but later canceled the bug as this behavior was by design. The reason is that FPWC hasn’t been refactored to support new content types. In Alfs blog post he searches for a string property and this actually works but this is not intended behavior.

So If you in the beginning of a project have known functions that you plan to solve by FPWC and page reference properties it might be best to avoid placing those page reference properties in a block.

Mar 24, 2014

Comments

Please login to comment.
Latest blogs
Adding Geolocation Personalisation to Optimizely CMS with Cloudflare

Enhance your Optimizely CMS personalisation by integrating Cloudflare's geolocation headers. Learn how my Cloudflare Geo-location Criteria package...

Andy Blyth | Nov 26, 2024 | Syndicated blog

Optimizely SaaS CMS + Coveo Search Page

Short on time but need a listing feature with filters, pagination, and sorting? Create a fully functional Coveo-powered search page driven by data...

Damian Smutek | Nov 21, 2024 | Syndicated blog

Optimizely SaaS CMS DAM Picker (Interim)

Simplify your Optimizely SaaS CMS workflow with the Interim DAM Picker Chrome extension. Seamlessly integrate your DAM system, streamlining asset...

Andy Blyth | Nov 21, 2024 | Syndicated blog

Optimizely CMS Roadmap

Explore Optimizely CMS's latest roadmap, packed with developer-focused updates. From SaaS speed to Visual Builder enhancements, developer tooling...

Andy Blyth | Nov 21, 2024 | Syndicated blog

Set Default Culture in Optimizely CMS 12

Take control over culture-specific operations like date and time formatting.

Tomas Hensrud Gulla | Nov 15, 2024 | Syndicated blog

I'm running Optimizely CMS on .NET 9!

It works 🎉

Tomas Hensrud Gulla | Nov 12, 2024 | Syndicated blog