Is there a jQuery plugin that will allow you to sort the list of elements ( <li>...</li>) according to their metadata stored as a hidden element? For example, each list item has two hidden inputs: authorand year. I want to sort the list using these hidden elements. I wonder if there is a ready-to-use plugin for jQuery. So far I have not found such a plugin. The only thing I found was sorting tables.
<ul>
<li>Position 1
<input type="hidden" name="author" value="Peter"/>
<input type="hidden" name="year" value="2004"/>
</li>
<li>Position 2
<input type="hidden" name="author" value="John"/>
<input type="hidden" name="year" value="2005"/>
</li>
<li>Position 3
<input type="hidden" name="author" value="Tony"/>
<input type="hidden" name="year" value="2006"/>
</li>
</ul>
source
share