You could store employee information into a javascript object: var employees = [ { id: '1', sex: 'm', city: 'Paris' }, { id: '2', sex: 'f', city: 'London' } ... ... <看更多>
forEach(function( element, index ) { // and update the jQuery object $elements[ ... which return a JavaScript array, and then the sort method It means that, ... ... <看更多>