Imagine the following hierarchy of pages + structure groups (with the stated metadata field):
- (StructureGroup): Section [MetadataField: BodyCssClass (text)]
- (StructureGroup): About
- (Page): Default
- (StructureGroup): Contact
- (Page): Default
- (StructureGroup): Help
- (Page): Default
All pages have the same page template which contains 'Add inherited metadata to page'.
In my page view I write
<body class="@(Page.MetadataFields["BodyCssClass"])">
I publish all 3x pages which each gather the structure group metadata field 'BodyCssClass' and become an instance, for each page, in the broker.
Therefore, the metadata value is duplicated for Nx pages under the structure group.
When the structure group field is changed the editor must republish all pages for the change to take effect other wise some pages end up with the old colour.
I just wondered if anyone faced the same scenario and if anyone could suggest a way to avoid the republish of all pages?
Note: The example here is to help explain the scenario, I'm interested in the actual scenario (the need to republish) rather than a solution for this example/
Note: Also, the editor can publish the structure group, so this isn't such a problem, I was just looking for a more elegant solution.
Thanks in advance