Show TOC

Online Application Plugin OverviewLocate this document in the navigation structure

The Kapsel Online Application plugin allows an online application, a web application running on a remote web server, to run within a Kapsel application. The developer passes a remote web application URL to the plugin and it loads the content from the web server in the application's web view.

The plugin is supported for use with applications on the Android and iOS platforms.

Loading the Content from a Web Server

Another way to implement this feature is to have the Cordova webview (browser) load the content from the web server instead of including the HTML5 files as part of the app. The app detects that it is being loaded in a Cordova container and then dynamically includes cordova.js and utils.js.

User Agent Prefix

To include a prefix to the web view's user agent string, include the following text in config-xml in the application project:

<preference name="UserAgentPrefix" value=""/>

Assign the value you want to prefix in the value field.

Plugin List in HTTP Header

On iOS, the online application plugin adds a session cookie named X-CORDOVA-PLUGINS that includes a comma-separated list of the Cordova plugins. When the page starts to load, it sets a cookie for the target server that makes the header appear in each request. This can be used for feature detection by the server or the client. The values can be accessed in JavaScript via a document.cookie and can be seen when debugging using Web Inspector.