0

I want to clarify in manifest that AJAX-calls to web-services only get executed when online. For that I used the NETWORK section of the manifest:

NETWORK:
/WebServices/*

But this causes calls of the error-callback of the JQuery function $.getJSON at every request even when online.

Marvin Emil Brach
  • 3,984
  • 1
  • 32
  • 62

1 Answers1

0

It seems that the WebView of Android doesn't like the wilcard *. Then when adding all URLs called by AJAX functions it works like expected:

NETWORK:
/WebServices/Typen
/WebServices/Hersteller
...

But that's endless work when developing an webapp. So I decided to put all the functions with AJAX-requests in a separate file. This file now gets an entry in the FALLBACK section of the manifest:

FALLBACK:
js/webServices.js js/ajaxStub.js

Every function contained in webServices.js is implemented again in the fallback file ajaxStub.js while returning default-values or store data to submit to the server.

Marvin Emil Brach
  • 3,984
  • 1
  • 32
  • 62