You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by "Andrew Grieve (JIRA)" <ji...@apache.org> on 2012/08/13 16:18:38 UTC
[jira] [Closed] (CB-1228) Read File never executes callback
onloadend in iOS 6
[ https://issues.apache.org/jira/browse/CB-1228?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andrew Grieve closed CB-1228.
-----------------------------
Resolution: Duplicate
> Read File never executes callback onloadend in iOS 6
> ----------------------------------------------------
>
> Key: CB-1228
> URL: https://issues.apache.org/jira/browse/CB-1228
> Project: Apache Cordova
> Issue Type: Bug
> Components: iOS
> Affects Versions: 1.7.0, 2.0.0
> Environment: iOS 6 Simulator and installed on a device wit the iOS6 Beta installed on
> Reporter: Bernhard Bezdek
> Assignee: Shazron Abdullah
> Labels: javascript
>
> File APi from Website doesen't work on iOS6 if I want to Read a file (text).
> This is my modified Version which is working fine on iOS lower Version 6
> function getFile(sFileName, oCallback) {
> window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, function(fileSystem) {
> fileSystem.root.getFile(sFileName, {
> create : true
> }, function(fileEntry) {
> fileEntry.file(function(file) {
> var reader = new FileReader();
> reader.onloadend = function(evt) {
> alert('READ FILE')
> window[oCallback](evt.target.result, sFileName);
> };
>
> reader.readAsText(file); // callback never executed
>
> }, function(error) {
> alert('Error C')
> });
> }, function() {
> alert('Error B')
> });
> }, function(error) {
> alert('Error A')
> });
> }
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira