Some sorting fixes.

Bug #1340 - the proper sort is dateTaken.