I have a set of textboxes which I want to iterate in order to get a list of their values. So I used the following appraoch:
var locations = []; $("input[