Set custom Country, Region and City for website visitor and perform visitor’s location based actions. It’s a simple to use PHP, mySQL and Ajax based script to add city, state and country dropdown chained select list for your website. PHP mySQL User Location is a PHP based webapp that lets your website’s visitor choose or set country, region and city from mySQL database. Countries, regions (states, provinces, territory) and cities database associated with this app is light weight to facilitate import / export for localhost or online database server. It also contains country codes, region codes, longitudes and latitudes. Database has been broken down to small parts that can be imported separately from multiple files into phpMyAdmin.
After country, region and city is set on a website, website can perform location based actions. You can redirect website users to specific sections based on their location. For example, if you have got a classified (online advertisement) website, you can enable users to store and view local ads from their own location. Enable your website to respect user’s location. Admin section (to manage locations database) is included as well. You don’t need to be a PHP expert to understand and use this.
BONUS: We have also included a method to auto detect and store ‘visitor’s country’ and ‘country code’.
- 246 Countries, 4151 Regions (states, provinces, territories), 103818 cities with Country Codes, Region Codes, Longitudes and Latitudes
- mySQL database of total 9.41 MB in size, broken down in 8 *.sql files for easy import/export actions. Import countries, regions and cities in database from separate sql files.
- Comes with admin section to add / edit countries, regions (states, provinces) and cities from database
- Bonus PHP script included (auto detect and set user’s country name and country code)
- Three level Chained Select Menu Control
- Country flags included
- jQuery / Twitter Bootstrap / FontAwesome support
- Fully supported PHP, mySQL, jQuery based webapp
- Well written documentation
- Well commented, clean code
- Easy to understand and use