The closest I can think of is Splash Access's guest WiFi solution, which allows for advertising on your guest portal (it doesn't replace advertising on other web sites).
Splash Access Multi Pro | Splash Access
They also offer a "white label" mobile app (so you can apply your own branding and call it your app). It does support geographic based pop ups (from memory). For example, you could have it pop up a note when someone is within a certain distance of a property for sale.
Going sideways, replacing adverts from other web sites could easily lead to your firm getting sued (not the guest wifi users - but your company - you can't contract out of it). For example, if a web page contains a trademark, you could be seen to be "passing off" using their trademark. If it is shown you did that on purpose (and you would be) - that is tripple damages.
Then there is the issue of creating a derived copyright work.
Then there is the Digital Millennium Copyright Act to consider.
If you did this on a big brand, like Coke-Cola, you won't be in business anymore.