Copied to clipboard

Flag this post as spam?

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


  • Claushingebjerg 939 posts 2574 karma points
    Nov 04, 2010 @ 15:40
    Claushingebjerg
    0

    exclude nodetypealias in 4.5

    How do i achieve the following in 4.5 schema?

     

    <xsl:for-each select="$parent/node [string(./data [@alias='umbracoNaviHide']) != '1' and @level &lt;= $maxLevelForSitemap and @nodeTypeAlias!='NewsItem' ']">

    i've come this far, but it doesnt work

      <xsl:for-each select="$parent/* [@isDoc and string(umbracoNaviHide) != '1' and @level &lt;= $maxLevelForSitemap and @nodeTypeAlias!='NewsItem']"> 
  • Chriztian Steinmeier 2800 posts 8790 karma points MVP 8x admin c-trib
    Nov 04, 2010 @ 15:45
    Chriztian Steinmeier
    102

    Hi Claus,

    Try this:

    <xsl:for-each select="$parent/*[@isDoc] [not(self::NewsItem)][not(umbracoNaviHide = 1)][@level &lt;= $maxLevelForSitemap]">

    /Chriztian

  • Fergus Davidson 309 posts 588 karma points
    Jan 20, 2011 @ 14:28
    Fergus Davidson
    0

    i was also struggling with a similar issue today related to the absence of 'nodetypealias' in the new xml schema

    i found this article: http://our.umbraco.org/wiki/reference/xslt/45-xml-schema/no-more-@nodetypealias

    basically, instead of "@nodeTypeAlias!+'NewsItem'"

    you can now use "local-name()!='NewsItem'"

    [just thought this might help someone else]

Please Sign in or register to post replies

Write your reply to:

Draft