Return-Path: X-Original-To: apmail-cordova-issues-archive@minotaur.apache.org Delivered-To: apmail-cordova-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D23A219DED for ; Tue, 22 Mar 2016 00:07:30 +0000 (UTC) Received: (qmail 30930 invoked by uid 500); 22 Mar 2016 00:07:25 -0000 Delivered-To: apmail-cordova-issues-archive@cordova.apache.org Received: (qmail 30872 invoked by uid 500); 22 Mar 2016 00:07:25 -0000 Mailing-List: contact issues-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@cordova.apache.org Received: (qmail 30836 invoked by uid 99); 22 Mar 2016 00:07:25 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Mar 2016 00:07:25 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 7C3932C1F5C for ; Tue, 22 Mar 2016 00:07:25 +0000 (UTC) Date: Tue, 22 Mar 2016 00:07:25 +0000 (UTC) From: "Nikhil Khandelwal (JIRA)" To: issues@cordova.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CB-10896) Cookies are not stored for local documents MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CB-10896?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Nikhil Khandelwal updated CB-10896: ----------------------------------- Component/s: Android > Cookies are not stored for local documents > ------------------------------------------ > > Key: CB-10896 > URL: https://issues.apache.org/jira/browse/CB-10896 > Project: Apache Cordova > Issue Type: Bug > Components: Android > Environment: Android > Reporter: Gareth McCaughan > Labels: triaged > > (I am using Android 6.0.1 and Cordova 6.0.0, but I do not believe this issue is strongly version-specific.) > I am building a Cordova application which is a fairly thin wrapper around a small single-page web app. Setting document.cookie in its Javascript code appears to do nothing, and reading document.cookie always returns an empty string. > I believe this is because the document is a local one rather than one served by a remote server, and Android webviews do not by default permit the use of cookies in such documents. > It is possible to change this behaviour by calling CookieManager.setAcceptFileSchemeCookies(true); early enough in the app's lifecycle that no CookieManager object has yet been instantiated. In particular, doing this at the very start of MainActivity.onCreate appears sufficient. > Is there a good reason why this shouldn't be Cordova's default behaviour? (E.g., are such cookies shared between all apps on the device?) -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org For additional commands, e-mail: issues-help@cordova.apache.org