Make entry in nav not clickable and reroute I have an entry that acts as a parent to several children pages. Trying to make so that particular parent isn't clickable AND reroutes to homepage if address url is accessed.

Not sure if I can work something into existing nav code or if this needs to be done somewhere else, but here's the code, nonetheless. Thanks in advance.

&lt;ul&gt;
    {% set pages = craft.entries.section('page') %}
    {% nav page in pages %}
        &lt;li&gt;
            {{ page.getLink() }}
            {% ifchildren %}
                &lt;ul&gt;
                    {% children %}
                &lt;/ul&gt;
            {% endifchildren %}
        &lt;/li&gt;
    {% endnav %}
&lt;/ul&gt;
You can use the level method to determine which iteration of the nav you are on and change the behavior:

&lt;ul&gt;
    {% set pages = craft.entries.section('page') %}
    {% nav page in pages %}
        &lt;li&gt;
            {% if page.level == 1 %}
                &lt;a href="/"&gt;{{ page.title }}&lt;/a&gt;
            {% else %}
                {{ page.getLink() }}
            {% endif %}
            {% ifchildren %}
                &lt;ul&gt;
                    {% children %}
                &lt;/ul&gt;
            {% endifchildren %}
        &lt;/li&gt;
    {% endnav %}
&lt;/ul&gt;


of if it's only one particular entry, then you can create a conditional to check for that entry (using slug, id, title, or any other attribute or field value).

&lt;ul&gt;
    {% set pages = craft.entries.section('page') %}
    {% nav page in pages %}
        &lt;li&gt;
            {% if page.slug == "myPage" %}
                &lt;a href="/"&gt;{{ page.title }}&lt;/a&gt;
            {% else %}
                {{ page.getLink() }}
            {% endif %}
            {% ifchildren %}
                &lt;ul&gt;
                    {% children %}
                &lt;/ul&gt;
            {% endifchildren %}
        &lt;/li&gt;
    {% endnav %}
&lt;/ul&gt;


If the url is accessed directly you can add a redirect to the template.

{% if entry.level == 1 %}
    {% redirect siteUrl %}
{% endif %}