Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jay 12 posts 32 karma points
    Jul 10, 2012 @ 07:22
    Jay
    0

    How to create tab functionality dynamically?

     

    Hi,

    i want to create (e.g: image above) tab functionality which is dynamic for every different page, is it possible to do so?

     

     

    Regards,

    Jay

  • Fuji Kusaka 2203 posts 4220 karma points
    Jul 10, 2012 @ 07:43
    Fuji Kusaka
    0

    Hi Jay,

    Yes this is possible. You could just add some nodes under the parent nodes and have some property fields in it.  

    Then you could make use of a macro file either Razor or Xslt to display those nodes as tabs from the parent page.

    Your content structure would be something like

    Content
    Default
    -- Page 1
    ---- Description
    ---- Reviews
    ---- Videos
    -- Page 2
    ---- Description 1
    ---- Reviews 2

    Displaying your tabs from Page 1 or Page 2

    <ul>
    <xsl:for-each select="$currentPage/* [@isDoc][not(umbracoNaviHide = 1)]">
      <li>
        <a href="{umbraco.library:NiceUrl(@id)}">
          <xsl:value-of select="@nodeName"/>
        </a>
      </li>
    </xsl:for-each>
    </ul> 

    Hope this helps.

    // Fuji

Please Sign in or register to post replies

Write your reply to:

Draft