More in this section
Forums / Developing with Sitefinity / Add a custom field to a page

Add a custom field to a page

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
3 posts, 0 answered
  1. Pepperio
    Pepperio avatar
    9 posts
    30 Nov 2010
    20 May 2011
    Link to this post

    I'm assuming you can add custom fields to pages?? I've added this to the web.config

    <add key="Pages.TailorMadeSearchName" valueType="ShortText" visible="True" searchable="False" sortable="True" defaultValue=""/>

    and i've added this to PagePropertiesEdit.ascx and PagePropertiesInsert.ascx:

     <li class="MenuLabel">
                            <h5><asp:Label ID="Label8" runat="server" AssociatedControlID="TailorMadeSearchName"><asp:Literal ID="Literal15" runat="server" Text="<%$Resources:TailorMadeSearchName %>"></asp:Literal></asp:Label> <em id="Em1" runat="server"></em> <cc1:LabelToolTip HelpBoxCssClass="HelpBox" id="LabelToolTip1" runat="server" ToolTipTitle="<%$Resources:TailorMadeSearchName %>" ToolTipText="<%$Resources:TailorMadeSearchNameDescription %>" AlternateText="<%$Resources:AboutTailorMadeSearchName %>"></cc1:LabelToolTip></h5>
                            <asp:TextBox ID="TailorMadeSearchName" runat="server" MaxLength="125"></asp:TextBox>
                            <p class="example">
                                <asp:Literal ID="Literal16" runat="server" Text="<%$Resources:TailorMadeSearchNameNote %>"></asp:Literal>

    i can see the label and textbox in my page properties page fine, but its not persisting the value to the database. Normally this happens automatically if I do this say for the news module.. what am I missing?

    Also, once there, how do I access it programatically? From what I can see, ICmsPage doesnt have a GetMetaData('newfieldname') equivalent..

    Many thanks for your help in advance, Rebecca
  2. Pepperio
    Pepperio avatar
    9 posts
    30 Nov 2010
    24 May 2011
    Link to this post
    Hi does anyone have a solution to this? Has anyone added a custom field to the page? I still need to resolve it. tha

    thank you
  3. Radoslav Georgiev
    Radoslav Georgiev avatar
    3370 posts
    01 Feb 2016
    25 May 2011
    Link to this post
    Hi Pepperio,

    You can find how to add custom fields to your pages by visiting this forum thread.

    All the best,
    Radoslav Georgiev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
3 posts, 0 answered