I need help sorting through some data.
Say I type "piz" in a searchfield. I get in return and array with all the entries that contain "piz".
I now want to display them in the following order:
pizza
pizzeria
apizzetto
berpizzo
First the items that start with what I typed in alphabetical order then the ones that contain what I typed in alphabetical order.
Instead if I sort them alphabetically I get the following
apizzetto
berpizzo
pizza
pizzeria
Does anyone know how to do this?
Thanks for your help.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…