2

I've seen this in some examples, but it didn't seem to work when I tried it out. Basically, take a scenario where you have a placeholder name prefix, like "column" or "row", but in the actual placeholder names you have "column1" and "column2", etc. In the placeholder settings, you want a common placeholder setting for both, so you use the key "column*" to catch both placeholders.

Like I said, I've seen this in a book or article, but not a working code sample, so I don't know if it requires code/pipeline intervention.

1

1 Answer 1

3

With the new dynamic placeholders of Sitecore 9, you can add a seed. In this way you can reuse the name of your placeholder and reuse the placeholder settings. However, the placeholders have another key due to their seeds.

https://doc.sitecore.net/sitecore_experience_platform/developing/developing_with_sitecore/dynamic_placeholders

Example: @Html.Sitecore().DynamicPlaceholder("column", seed: 10)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.