I have an application where users type A posts information. By default these posts will be available to any web user, anywhere in the world.
But there is a possibility for user A to restrict his post 123 to some cities. In other words, userA has banned his post 123 from being available to people who access from the cities of Brasilia, Salvador and André da Rocha (small city of Rio Grande do Sul). I'm using random examples from small to medium-sized cities.
How to implement such functionality?
Let's consider that all users who will access the system will not be using proxy.
I'm using php.