title: Looking for a javascript solution to reorder divs
body: <p>I have some divs in the page that show different things of the same kind, for example offers, now offers have ending time, and also posted time, if the user wants to order by ending time, or posted time, they should be re ordered.</p>
  
  <p>I'm looking for a javascript solution that could do that, any particular libraries under Ext JS , or JQuery would work</p>
  
  <p>Here is how these divs look like</p>
  
  <pre><code>&lt;div data-sortunit="1" data-sort1="40" data-sort2="156" data-sort3="1"
  data-sort4="1317620220" class="item"&gt;
  &lt;/div&gt;
  
  &lt;div data-sortunit="2" data-sort1="30" data-sort2="116" data-sort3="5"
  data-sort4="1317620220" class="item"&gt;
  &lt;/div&gt;
  
  &lt;div data-sortunit="3" data-sort1="10" data-sort2="157" data-sort3="2"
  data-sort4="1317620220" class="item"&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>So I wanna be able to sort these divs based on data-sortN, N being an integer</p>