title: Nested comments, sort array to list child after their parent
body: <p>I'm trying to make a comment system with nested comments. But, I only want indentation for the whole reply block so I don't end up with ex. 2 indentations if there is a reply to the reply.</p>
  
  <p>So I want something like this</p>
  
  <pre><code>Parent
    Child
    Child
    Child
  Parent
  </code></pre>
  
  <p>I got an array with all comments looking like this (removed things like date, name etc)</p>
  
  <pre><code>Array ( 
      [0] =&gt; Array ( [ID] =&gt; 1 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 0 ) 
      [1] =&gt; Array ( [ID] =&gt; 2 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 1 )
      [2] =&gt; Array ( [ID] =&gt; 3 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 0 )
      [3] =&gt; Array ( [ID] =&gt; 4 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 2 )
      [4] =&gt; Array ( [ID] =&gt; 5 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 0 )
      [5] =&gt; Array ( [ID] =&gt; 6 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 1 )
      [6] =&gt; Array ( [ID] =&gt; 7 [BLOG_ID] =&gt; 3 [REPLY_TO] =&gt; 0 )
  )
  </code></pre>
  
  <p>How can I sort the array so the child's are listed after their parent?</p>