Copied to clipboard

Flag this post as spam?

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


  • Nathan Syverson 4 posts 24 karma points
    Feb 11, 2011 @ 05:54
    Nathan Syverson
    0

    Problems getting pages with a future date

    I know this has been answered a million times in a million ways, but I can't seem to understand what I am doing wrong.  I've looked at a lot of posts, and have gotten errors ranging from string is in improper format to having noting show up on the page.

    Basically, for my church I have a worship schedule page, with subpages for each worship service.  Worship Service Documents have a dateAndTime.  I want to list future Worship Services

    
    
    
    
    
    
    
    
    p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 16.0px; font: 13.0px Courier; color: #22881a}
    p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 16.0px; font: 13.0px Courier; min-height: 16.0px}
    p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 16.0px; font: 13.0px Courier; color: #aa28bb}
    p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 16.0px; font: 13.0px Courier; color: #aa771a}
    p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 16.0px; font: 13.0px Courier}
    span.s1 {color: #000000}
    span.s2 {color: #aa28bb}
    span.s3 {color: #002efa}
    span.s4 {color: #22881a}
    
    
    
    

    <xsl:param name="currentPage"/>

     

    <xsl:template match="/">

     

    <!-- The fun starts here -->

    <ul>

      <xsl:for-each select="$currentPage//child [umbraco.library:DateGreaterThanOrEqualToday(data [@alias='dateAndTime'])=true] ">

      <xsl:sort select="./dateAndTime" order="ascending"/>

        <xsl:if test="1=1">

        <li>

          <a href="{umbraco.library:NiceUrl(@id)}">

            <xsl:value-of select="@nodeName"/>

          </a>

        </li>

      </xsl:if>

    </xsl:for-each>

    </ul>

  • Nathan Syverson 4 posts 24 karma points
    Feb 11, 2011 @ 05:55
    Nathan Syverson
    0

    So I guess the question would be, what would make this line work>

    <xsl:for-each select="$currentPage//child [umbraco.library:DateGreaterThanOrEqualToday(data [@alias='dateAndTime'])=true] ">


  • Kim Andersen 1447 posts 2197 karma points MVP
    Feb 12, 2011 @ 16:07
    Kim Andersen
    0

    Hi Nathan!

    Which version of Umbraco are you using? And do you want to run through all the child nodes from the current page or just some of them?

    /Kim A

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies