Welcome To Snipplr
Everyone's Recent Snippets Tagged sort
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
Probably not the most elegant solution, but it works. Needed this for a capistrano deploy task which shows the most recent tagged releases in my repository. Very bare bones, and needs tweaking if your versions are not in X.X.X.X format.
1
925
posted 15 years ago by bananastalktome
an external javascript sort function, which you can import into flash to help sort arrays of objects. include the script thus:
#include "objSort.js"
2
982
posted 15 years ago by stiobhart
This code replaces a normal category template. It sorts all posts by their category/subcategory instead of bunching them all together and ordering them by date. A bit complicated to explain in a box this size... Check the link for a run through!
1
914
posted 15 years ago by rocktronica
Add this to your Utilities class and use it like Utilities.moveToTop(your_clip);
2
836
posted 15 years ago by ozke
Put this before the loop in archive.php to have posts in the archive for category '26' sorted by custom field 'date'.
Assign sortable values like '090501' or '2009-05-01' to those fields when editing posts and your Upcoming Events will be sorted by...
8
1889
posted 15 years ago by hussong
This is a function that selects files from a directory and orders them by the last time they were changed, in ascending or descending order. The snippet also calculates how much time passed since the file’s content was changed.
2
1608
posted 15 years ago by fackz
This is a very simple bookmarklet that will temporarily sort the *visible* messages in Gmail by subject. You'll have to run it again each time Gmail refreshes the list.
[Sort Gmail Messages](javascript:(function(){function%20f(r){var%20t=r...
0
1002
posted 15 years ago by wizard04
jQuery Plugin for returning selected DOM Nodes in DOM order. e.g. $('img.L,img.Y') will not be guaranteed DOM order (usually all the L's then all the Y's).
Currently only works with IE and FF (that's all I needed).
1
859
posted 16 years ago by kouphax
This function will sort an array of DOM elements in order of the DOM position. Useful when using calls such as $$("img.L,img.M") which doesn;t return a sorted element array.
It uses prototype but you can replace the Prototype.Browser stuff with a...
0
1099
posted 16 years ago by kouphax