I am having a local business website created but confused on how to code the site so that the user may search for businesses within a certain miles radius. I have seen many websites out there with the feature where they can search business within 10-20-30-40etc from their area. I have purchased a database of zip codes, city states and their coordinates.
According to what you have mentioned, you need to find whether a given point is within a circle or not. See How to find places within a given radius. But you need a more convenient approach for this. Since you already have the table with long, lat, following is the php/mySql based code for you. How to find places within a circle Hope it will help you.