More in this section
Forums / Developing with Sitefinity / Custom meta fields

Custom meta fields

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.
2 posts, 0 answered
  1. Pierre
    Pierre avatar
    433 posts
    16 Feb 2006
    11 Oct 2007
    Link to this post

    Generic Content
    based modules (Generic Content, News, Blogs) have the ability to define custom meta fields. You are found one sample with Sub-title and in one last post one link to pdf files. 

    I need to add more images, texts, numbers to the news module. Could you use this properties.

    Could you explain more what are the diffent customs fields that I can add to the News Module by this way. Only text?.

    Could you found another sample for more custom fields

    Best regards

  2. Sonya
    Sonya avatar
    231 posts
    24 Sep 2012
    12 Oct 2007
    Link to this post
    Hi Pierre,

    All Generic Content based modules have the ability to define custom meta fields. If you want to add a custom meta field, you must follow these steps:

    1. Define a meta field to the module (example: PDFAttachment to the News module)
    2. Add control that will accept the URL of the new field (attachment)
    3. Add Hyper Link control that will display this URL in the given control (example: in SingleNews and/or NewsList control for the PDF attachement).

    The meta fields are changed in the web.config in the <metaFields> tag section. There, in order to add a new meta field, the following type of code should be added (this is just part of the example):

    <asp:HyperLink ID="PDFAttachement" runat="server" NavigateUrl='<% = this.Text %>'></asp:HyperLink> 

    Also, the valueType key could be specified. The different predefined value types of meta fields are:
    • ShortText
    • LongText
    • DateTime
    • Integer
    • FloatingPoint
    • Boolean
    • Guid
    • Binary
    For detailed explanation, please look at the  following thread:  Adding Meta Fields.

    Hope this helps.

    Kind regards,
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
2 posts, 0 answered