|
Well, the easiest way would be to use a database, but from your post it seems you're trying to do it without. There's a few different ways I can think of, non very simple: you can make 24 arrays, 1 array per letter of the alphabet, and when that letter is typed in, you show the contents of the array in a div. Or you can put all the names in one array and loop through the whole thing.
Keep in mind that when showing the names, each one will have to be in it's own element so you can implement the "user-choosing" function.
|