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

Forums / Developing with Sitefinity / Tag cloud lay out

Tag cloud lay out

4 posts, 0 answered
  1. Katrien
    Katrien avatar
    4 posts
    Registered:
    06 Oct 2011
    06 Oct 2011
    Link to this post
    Hi,

    I have a question on the tag cloud lay out. I have made a Tag list for my blog and all tags appear under each other. Is there a way I can change it so they are just separated by a space in stead of an enter? (I use Sitefinity 3.7)

    Thanks for helping!

    Kind Regards,
    Katrien
  2. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    30 Nov 2016
    11 Oct 2011
    Link to this post
    Hi Katrien,

    If you select the tag list control to be displayed as a cloud, the tags will be displayed on one row one after the other. You can specify this by editing clouds list widget, expand appearance tab and select DefaultDisplayMode - cloud.
    When tags are displayed as a list their html representation is in <ul> element which makes them render in rows.

    All the best,
    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
  3. Katrien
    Katrien avatar
    4 posts
    Registered:
    06 Oct 2011
    11 Oct 2011
    Link to this post
    Hey Stanislav,

    I think I was a little bit un-clear with my question.

    I have set up the tag list as a cloud. And all the tags are depicted in 1 row. My question was if there is anything I can do so that they won't appear in 1 row. I want it to look more like this:


    How do I make that happen?
  4. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    Registered:
    30 Nov 2016
    13 Oct 2011
    Link to this post
    Hi Katrien,

    To modify tags list control you need to create a custom control that inherits from TagsList and load its modified template. Here is related blog post and a forum post and forum post.

    The template for tags list is.
    <%@ Control Language="C#" %>
    <h3>
        <asp:Literal ID="controlTitle" runat="server"></asp:Literal>
    </h3>
    <p>
        <asp:Literal ID="lblDisplayAs" runat="server" Text='<%$Resources:DisplayAs %>'></asp:Literal> :
        <asp:LinkButton ID="displayCloudLink" runat="server" Text='<%$Resources:Cloud %>'></asp:LinkButton> |
        <asp:LinkButton ID="displayListLink" runat="server" Text='<%$Resources:List %>'></asp:LinkButton>
    </p>
     
    <asp:Repeater ID="tagsRepeaterCloud" runat="server">
        <HeaderTemplate><ul class="tagCloud"></HeaderTemplate>
        <ItemTemplate>
            <li><asp:HyperLink ID="tagLink" runat="server" CssClass="tagCloudItem"></asp:HyperLink></li>
        </ItemTemplate>
        <FooterTemplate></ul></FooterTemplate>
    </asp:Repeater>
     
    <asp:Repeater ID="tagsRepeaterList" runat="server">
        <HeaderTemplate><ul></HeaderTemplate>
        <ItemTemplate>
            <li>
                <asp:HyperLink ID="tagLink" runat="server"></asp:HyperLink>
                (<asp:Label ID="taggedContentCount" runat="server"></asp:Label>)
            </li>
        </ItemTemplate>
        <FooterTemplate></ul></FooterTemplate>
    </asp:Repeater>


    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
Register for webinar
4 posts, 0 answered