Re: check wallet garden / internet connection

2014-12-23 Thread marian lux
Okay thank you for the overview of possibilities. I will investigate the CORS approach. Am Montag, 22. Dezember 2014 19:07:07 UTC+1 schrieb Jens: You have to live with the JavaScript constraints which means you either make a request to the domain the app is served from or the server must

check wallet garden / internet connection

2014-12-22 Thread marian lux
I need to check if my GWT application is inside a wallet garden (wifi hotspot without internet connection). How to handle this in an easy way on client side? Is there a way to ping e.g. google.com and return true/false in a method like boolean isInWalletGarden(); ? Can anyone post such a

Re: check wallet garden / internet connection

2014-12-22 Thread Chad Vincent
1) Walled Garden 2) Any attempt to contact a different server in the javascript will trigger a security warning in most browsers, if not be blocked. You certainly can try and perform an HTTP request via RequestBuilder, but I wouldn't count on it being reliable. On Monday, December 22, 2014

Re: check wallet garden / internet connection

2014-12-22 Thread marian lux
Yes RequestBuilder is not working. The response-code there is always = 0 (same origin policy). Today I use as workaround JsonpRequestBuilder and try to receive JavaScriptObjects from http://gdata.youtube.com/feeds/api/videos?;. But there must be a better way to handle this. E.g. I want to

Re: check wallet garden / internet connection

2014-12-22 Thread marian lux
Something like this http://stackoverflow.com/questions/13958614/how-to-check-for-unrestricted-internet-access-captive-portal-detection in GWT would be nice! Am Montag, 22. Dezember 2014 18:30:09 UTC+1 schrieb marian lux: Yes RequestBuilder is not working. The response-code there is always =

Re: check wallet garden / internet connection

2014-12-22 Thread Jens
You have to live with the JavaScript constraints which means you either make a request to the domain the app is served from or the server must support CORS headers to allow cross origin requests. If both are not possible then JSONP is the only other solution to make requests to any domain that