<p>You could <s>try using</s> use the <code>reverse</code> twig filter.</p>

<pre><code>{% for entry in craft.entries.section('volumes')|reverse %}
...
{% endfor %}
</code></pre>

CC BY-SA 3.0
2014-10-08T17:17:40.130Z
Wouldn't this just reverse the default order, which is `'postDate desc'`?
carlcs
CC BY-SA 3.0
2014-10-08T17:26:35.190Z
IGNORE my comment. If it's a structure, the default order is in fact the sort order of the entries in the CP. Just tried the `reverse` filter and it works as you said.
carlcs
CC BY-SA 3.0
2014-10-09T09:08:44.393Z
Thanks so much for your help. This should also be the answer but because carlcs's answer addresses the first method of solving the problem, I thought it more suitable to tick that one.
bravokiloecho
CC BY-SA 3.0
2014-10-09T14:59:53.357Z
No worries. I like his answer also. I learned something new! ;)
Douglas McDonald
CC BY-SA 3.0
2014-10-08T17:13:42.457Z
2014-10-08T17:27:26.160Z
2014-10-08T17:27:26.160Z
Douglas McDonald
<p>The primary parameter you're looking for is <code>lft</code>:</p>

<pre><code>craft.entries.section('volumes').order('lft desc')
</code></pre>

CC BY-SA 3.0
2014-10-09T09:09:25.450Z
Thanks carlcs. Very useful. Handy that the Craft documentation fails to mention that parameter!
bravokiloecho
CC BY-SA 3.0
2014-10-08T17:29:23.867Z
2014-10-08T17:29:23.867Z
carlcs
<p>How do you output the all the children of a structure in a reverse order (assuming the children are limited to max depth).</p>

<p>Using the <a href="http://buildwithcraft.com/docs/templating/craft.entries#order" rel="noreferrer">order parameter</a>, Craft requires that you use a second parameter like <code>"desc"</code> after a primary order parameter (eg, <code>"title"</code>). This would look like:</p>

<pre><code>craft.entries.section('volumes').order('title desc')
</code></pre>

<p>But what would be the primary parameter that would respect the natural structure order?</p>

<p>Or is there any other way? </p>

<structure><sections><ordering>
Output children of a structure section in reverse order
# Output children of a structure section in reverse order

(Asked by: username_0 on 2014-10-08)

How do you output the all the children of a structure in a reverse order (assuming the children are limited to max depth).
Using the order parameter, Craft requires that you use a second parameter like "desc" after a primary order parameter (eg, "title"). This would look like:
craft.entries.section('volumes').order('title desc')

But what would be the primary parameter that would respect the natural structure order?
Or is there any other way?

**Tags:** structure, sections, ordering


---

## 2 answers

### Answer by username_2 on 2014-10-08. Score: 14 | Accepted answer

The primary parameter you're looking for is lft:
craft.entries.section('volumes').order('lft desc')

> **Comments:**
> **username_0**: Thanks username_2. Very useful. Handy that the Craft documentation fails to mention that parameter!  

---

### Answer by username_1 on 2014-10-08. Score: 8

You could try using use the reverse twig filter.
{% for entry in craft.entries.section('volumes')|reverse %}
...
{% endfor %}

> **Comments:**
> **username_2**: Wouldn't this just reverse the default order, which is `'postDate desc'`?  
> **username_2**: IGNORE my comment. If it's a structure, the default order is in fact the sort order of the entries in the CP. Just tried the `reverse` filter and it works as you said.  
> **username_0**: Thanks so much for your help. This should also be the answer but because username_2's answer addresses the first method of solving the problem, I thought it more suitable to tick that one.  
> **username_1**: No worries. I like his answer also. I learned something new! ;)  

---

