It is better to do this at front server like nginx, Apache or even at os-level. In web2py, models files are processed for each request, so you can just raise HTTP at db.py
вторник, 27 октября 2020 г. в 04:52:57 UTC+3, Vlad: > I've discovered that my site is constantly bothered by weird locations - > not that there is anything intrinsically wrong with those countries, but > those locations have nothing to do with actual customers. I want to reject > the requests from those locations altogether. > > I can reject any specific page in controller code, but how do I reject ANY > request altogether, without coding it into multiple places? > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/36ef2c26-b63f-48f1-b032-51f4774171c6n%40googlegroups.com.

