1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / General Discussions / Download List

Download List

10 posts, 0 answered
  1. James Greaves
    James Greaves avatar
    25 posts
    Registered:
    21 Oct 2009
    07 Dec 2010
    Link to this post
    Hi,

    How do I go about getting the download list to display the document title...rather than the document file name? 

    Is this possible out of the box or do I need to create a custom widget? 

    Any help, as always is appreciated.


    Cheers,
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    07 Dec 2010
    Link to this post
    Hello James,

    We set the document file name as a document title during upload. You can edit the item after it has been uploaded and modify its title.

    In our code we get the Document Title and display it by MasterListView of the control

    var document = (Document)dataItem;
    documentLink.Text = document.Title;
    documentLink.ToolTip = document.Description;
    documentLink.NavigateUrl = document.MediaUrl;


    Best wishes,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. James Greaves
    James Greaves avatar
    25 posts
    Registered:
    21 Oct 2009
    08 Dec 2010
    Link to this post
    Thanks again Ivan!

    I figured that this is what should have happened but due to an upload error it did not.  I noticed that uploading a set of large files caused IE to crash, this locked the files in all kinds of weird ways which caused this issue.  (I have a video of this happening if you want it.

    While I am on the matter...How do I go about changing the appearance of the download List on SF4?

    Thanks in advance,


  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    08 Dec 2010
    Link to this post
    Hello James,

    We received some other requests about issues with IE, but we did not mange to replicate any issues, so if you can share the video with us we will follow your steps and try to figure out what the problem is.

    Changing appearance of DownloadList - you can add css classes to your theme stylesheet that will change the appearance of the control, you can use some of the built-in options in the ControlDesigner of the control and you can map the template to the control by using LayoutTemplatePath property

    Below is the control template.

    <%@ Register TagPrefix="sitefinity" Namespace="Telerik.Sitefinity.Web.UI" Assembly="Telerik.Sitefinity" %>
     
     
    <div id="itemsContainer" runat="server">
        <asp:Repeater ID="documentsRepeater" runat="server">
            <HeaderTemplate>
                <ul class="sfdownloadList sfListMode">
            </HeaderTemplate>
            <ItemTemplate>
                <li id="docItem" runat="server" class="sfdownloadFile">
                    <sitefinity:SitefinityHyperLink ID="documentLink" runat="server" CssClass="sfdownloadTitle" target="_blank" />
                    <sitefinity:SitefinityLabel id="infoLabel" runat="server" WrapperTagName="div" HideIfNoText="false" CssClass="sfInfo" />
                </li>
            </ItemTemplate>
            <FooterTemplate>
                </ul>
            </FooterTemplate>
        </asp:Repeater>
    </div>
    <sitefinity:Pager id="pager" runat="server" NavigationMode="Links"></sitefinity:Pager>


    All the best,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. Madhavan
    Madhavan avatar
    19 posts
    Registered:
    31 Jan 2011
    17 Mar 2011
    Link to this post
    Hi,

      Is it possible to make the list pick only specific categories?

    Thanks
    Madhavan
  6. James Greaves
    James Greaves avatar
    25 posts
    Registered:
    21 Oct 2009
    18 Mar 2011
    Link to this post
    Madhavan,

    I may be over simplifying what you want here...but you should just be able to do select categories on the widget.

    See attached picture.
  7. Mark
    Mark avatar
    9 posts
    Registered:
    20 Feb 2009
    20 Jul 2011
    Link to this post
    Hi Ivan, 

    I'm trying to do something but can't seem to find an answer.  I saw this thread from an earlier version, and believe the problem is the same.   I have the documentlist widget added to a page.   I have a document library (Press Releases) whose documents I am displaying in the control.  I added a custom field called "Header", as the library fields were insufficient for my needs.  

    I want to display the documentlist, but don't want to use the file name as the link back to the document (I don't want to see it at all). I made a change to the documentlist template to hide the file name field:

    <sitefinity:SitefinityHyperLink ID="documentLink" runat="server" Visible="false" CssClass="sfdownloadTitle" target="_blank" />

    I then added the field that I want to include in the document list below:

    <sitefinity:TextField runat="server" DisplayMode="Read" Value='<%# Eval("Heading")%>' />

    But, I don't know how to make the "Heading" field the file link, instead of the filename.   Any ideas how to change this in version 4?

    Mark
  8. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    23 Aug 2017
    25 Jul 2011
    Link to this post
    Hi Mark,

    You can not modify SitefinityHyperLink because the ID it uses get the Title and the URL to the document. You can use
    <asp:HyperLink ID="HyperLink1" runat="server" navigateUrl="http://localhost:60876/docs/press-release/document.docx?Status=Master">    <sitefinity:TextField runat="server" DisplayMode="Read" Value='<%# Eval("NEWField")%>' /></asp:HyperLink>
    This approach does not provide you with using NavigateUrl with a dynamic url for each document but rather hardcoding the link to each document in the list.
    I recommend getting the URL string which is generated from <sitefinity:TextField runat="server" DisplayMode="Read" Value='<%# Eval("MediaUrl")%>' /> with javascript since the asp:hyperlink and <a href=""> read the tagged text directly and not like URL.


    Best wishes,
    Stanislav Velikov
    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
  9. Kim
    Kim avatar
    2 posts
    Registered:
    26 Jul 2011
    29 Jul 2011
    Link to this post
    Stanislov, 

    So the only way to use probably the most important widget in the CMS is to display the links by file?   I will have to rename every file in my document libraries to display them, or will have to use something like the content widget and hardcode links back to documents in the library (and not be able to take advantage of using filtering and sorting).  Is that correct?

    Mark
  10. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    01 Aug 2011
    Link to this post
    Hi Kim,

    If you configure the widget to works in List + Detail page or Table + Detail page you will see a download link

    <sf:SitefinityHyperLink ID="documentLinkBottom" runat="server" CssClass="sfdownloadLink" target="_blank" />

    which shows the link by a file.

    Generally we set the document.Media url property of the hyperlinks, so this could be done easily in a custom or a user control.

    All the best,
    Ivan Dimitrov
    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
10 posts, 0 answered