More in this section

Forums / Developing with Sitefinity / Modifying Blog Posts to allow file uploading

Modifying Blog Posts to allow file uploading

2 posts, 0 answered
  1. Gianluca
    Gianluca avatar
    9 posts
    Registered:
    04 Oct 2012
    07 Jan 2013
    Link to this post

    Hi everyone,

       I am pretty new to Sitefinity and am currently working with Sitefinity 5.1. I am trying to add a custom field to the Blog Posts Content Type to allow a user to use the file selector control to upload a file along with their blog post. Does anyone know how, or even if that functionality is available? If anyone could get back to me I would greatly appreciate it. 


    Gianluca

  2. Victor Velev
    Victor Velev avatar
    1345 posts
    Registered:
    06 Jul 2015
    10 Jan 2013
    Link to this post
    Hello Gianluca,

    At the moment we do not have a sample on how to upload a file ( for example a document ) to a module because this is not implemented as a definition element in the Sitefinity module.

    To upload a document refer to this sample that can either be added as a new custom field that will select the document or it can be integrated to the module and used as definition element that will select a document.

    In the selector change the services to use document selector service

    <sf:MediaContentSelectorView
        
                        CssClass="sfContentViews imageSelector"
                        id="leftSlideLogoImageSelector"
                        runat="server"
                        ContentType=Telerik.Sitefinity.Libraries.Model.Document
                        ParentType=Telerik.Sitefinity.Libraries.Model.DocumentLibrary
                        LibraryBinderServiceUrl="~/Sitefinity/Services/Content/AlbumService.svc/"
                        MediaContentBinderServiceUrl="~/Sitefinity/Services/Content/ImageService.svc/"
                        MediaContentItemsListDescriptionTemplate="Telerik.Sitefinity.Resources.Templates.Designers.Libraries.Images.ImageItemDescriptionTemplate.htm"
                        DisplayResizingOptionsControl="false"
                        ShowOpenOriginalSizeCheckBox="false">
                    </sf:MediaContentSelectorView>

    This will select document from Sitefinity document library.

    Greetings,
    Victor Velev
    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
2 posts, 0 answered