How to exclude a page from the navigation tree I am looking for a way to exclude certain pages from the navigation. I know it must be quite easy, but nothing seems to work for me at the moment. 

So I've setup a lightswitch field "exclude from navigation" (cf_hideFromNav)

Problem is that I want the navigation to start only from a certain slug: 

{% set topEntry = craft.entries.section('pages').depth(1).slug('club').first() %}
{% set descendants = topEntry.getDescendants()  %}              
&lt;ul&gt;
    {% nav entry in descendants %}
        &lt;li&gt;
            {{ entry.title }} 
            {% ifchildren %}&lt;ul&gt;{% children %}&lt;/ul&gt;{% endifchildren %}
        &lt;/li&gt;
    {% endnav %}
&lt;/ul&gt;


how could I incorporate the cf_hideFromNav in this equation?

any help appreciated!
cheers
stefan
Use a descendantOf parameter with a new ElementCriteriaModel instead of the getDescendants method on your entry model and you can add additional parameters. In your case add cf_hideFromNav as a parameter:

{% set topEntry = craft.entries.section('pages').slug('club').first() %}
{% set navItems = craft.entries.section('pages').descendantOf(topEntry).cf_hideFromNav('0') %}

{% nav navItem in navItems %}
    ...
{% endnav %}


You could also use the parameters id or slug to exclude certain entries:

{% set topEntry = craft.entries.section('pages').slug('club').first() %}
{% set navItems = craft.entries.section('pages').descendantOf(topEntry).id('and, not 23, not 40, not 12') %}


The descendantOf parameter also takes IDs. This would allow you to do this all with just a single ElementCriteriaModel:

{% set navItems = craft.entries.section('pages').descendantOf('1').id('and, not 23, not 40, not 12') %}