Ajax sorting finetuning