简体   繁体   中英

detect client on web application is local Or from internet

我怎么知道一个客户端,在我的Web应用程序中通过Wan(从Internet)连接,还是使用本地网络连接。如果有功能,请给我打电话。

You could setup/host a small web service that's only available within your intranet and try to hit it from the client javascript. If they are on your local network, it will be successful, else it will fail.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM