Posts

Showing posts from November, 2021

Quick Fixes: Rendering Parameters and Standard Values

Although the rendering parameters editor uses a template to define itself, it's important to remember that it does not actually render standard values--even though those values show up when you view the editor. This makes sense; the template is used to control what fields are exposed for editing, rather than to define a data structure for an item, and the editor must rely on the same methods that are used to populate the item editor. There isn't really a good way to get around this, because of the way the information is stored in a parameter string. Sitecore never asks for field values when it calculates the parameter string, only whether or not the key is found in the string. So, in my opinion, the best practice in this situation is to tie these values to the datasource item instead of the rendering parameters, and to avoid setting standard values for rendering parameter templates at all. This way you can take advantage of standard values without confusing your authors.