I know it might sound crazy, but is it possible to change the section name in an item depending on some rule. For instance, Sitecore has B and C templates which are inherited from A template, A has a section "My Section", but when the user is on an item that is created from template B, this "My Section" should be renamed to "My Section B".

I know it comes from:

// Sitecore.Shell.Applications.ContentEditor.EditorFormatter
using Sitecore.Diagnostics;
using Sitecore.Shell.Applications.ContentManager;
using System.Web.UI;

/// <summary>
/// Renders the section.
/// </summary>
/// <param name="section">
/// The section.
/// </param>
/// <param name="parent">
/// The parent.
/// </param>
/// <param name="readOnly">
/// if set to <c>true</c> this instance is read only.
/// </param>
public void RenderSection(Editor.Section section, Control parent, bool readOnly)
    Assert.ArgumentNotNull(section, "section");
    Assert.ArgumentNotNull(parent, "parent");
    bool isSectionCollapsed = section.IsSectionCollapsed;
    bool flag = !isSectionCollapsed || UserOptions.ContentEditor.RenderCollapsedSections;
    RenderSectionBegin(parent, section.ControlID, section.Name, section.DisplayName, section.Icon, isSectionCollapsed, flag);
    if (flag)
        for (int i = 0; i < section.Fields.Count; i++)
            RenderField(parent, section.Fields[i], readOnly);
    RenderSectionEnd(parent, flag, isSectionCollapsed);

enter image description here


this it an old article but seems like relevant

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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