You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ag...@apache.org on 2014/12/23 17:33:06 UTC

docs commit: CB-8144 ffos: Add systemXHR as a solution for whitelisting (close #248)

Repository: cordova-docs
Updated Branches:
  refs/heads/master 455ed5998 -> 05c6c9719


CB-8144 ffos: Add systemXHR as a solution for whitelisting (close #248)


Project: http://git-wip-us.apache.org/repos/asf/cordova-docs/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-docs/commit/05c6c971
Tree: http://git-wip-us.apache.org/repos/asf/cordova-docs/tree/05c6c971
Diff: http://git-wip-us.apache.org/repos/asf/cordova-docs/diff/05c6c971

Branch: refs/heads/master
Commit: 05c6c9719ddd1f1fbbdacd4405b40215736105a0
Parents: 455ed59
Author: Piotr Zalewa <pi...@zalewa.info>
Authored: Wed Dec 10 11:48:07 2014 +0100
Committer: Andrew Grieve <ag...@chromium.org>
Committed: Tue Dec 23 11:32:36 2014 -0500

----------------------------------------------------------------------
 docs/en/edge/guide/appdev/whitelist/index.md | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/05c6c971/docs/en/edge/guide/appdev/whitelist/index.md
----------------------------------------------------------------------
diff --git a/docs/en/edge/guide/appdev/whitelist/index.md b/docs/en/edge/guide/appdev/whitelist/index.md
index 48d91b0..155c5b7 100644
--- a/docs/en/edge/guide/appdev/whitelist/index.md
+++ b/docs/en/edge/guide/appdev/whitelist/index.md
@@ -195,6 +195,26 @@ ways:
 (For more information on support, see BlackBerry's documentation on the
 [access element][8].)
 
+## Firefox OS
+
+In Firefox OS there is no concept of whitelisting a specific domain. Instead
+there is a special permission called 
+[SystemXHR](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest#Permissions).
+There is a need to add this permission to `config.xml`:
+
+	<platform name="firefoxos">
+		<permission name="systemXHR" privileged="true" description="load data from server" />
+	</platform>
+
+The `XMLHttpRequest` object needs to be instantiated with two parameters 
+`mozAnon` and `mozSystem`:
+
+	var request = new XMLHttpRequest({
+		mozAnon: true,
+		mozSystem: true});
+
+This solution is transparent so there is no difference for other platforms.
+
 ## iOS Changes in 3.1.0
 
 Prior to version 3.1.0, Cordova-iOS included some non-standard


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org