Wow. Never mind that converting miles to degrees doesn't work so well if the chain is nationwide (meridians are farther apart in Florida than in Maine, so southern folk end up driving further E/W then perhaps they needed to). Unless that JScript looked up the starting zip for a center and compensated, which I doubt.
And, by the virtue of having a limiting circle, aren't they already computing distance with each row-compare in the SQL query? Or was that a limiting 'box'...
Ahh. I get it now. They never even bothered to compute the distance (maybe they forgot the Euclidean formula?) The zipcode was an arbitrary enough metric to sort on. I know, you can sort on ($MyZip - ZipCode)!
Because zip codes that are close numerically are often close geographically.