cordova-ourcodeworld-filebrowser
cordova-ourcodeworld-filebrowser copied to clipboard
Support for SDK Version 24 and higher
Please provide support for version 24 and higher. The app crashes when using an SDK version higher than 23.
FATAL EXCEPTION: main Process: io.ionic.starter, PID: 4990 android.os.FileUriExposedException: file:///storage/emulated/0/DCIM/Camera/IMG_20170720_180111.jpg exposed beyond app through ClipData.Item.getUri() at android.os.StrictMode.onFileUriExposed(StrictMode.java:1799) at android.net.Uri.checkFileUriExposed(Uri.java:2346) at android.content.ClipData.prepareToLeaveProcess(ClipData.java:832) at android.content.Intent.prepareToLeaveProcess(Intent.java:8909) at android.content.Intent.prepareToLeaveProcess(Intent.java:8894) at android.app.Activity.finish(Activity.java:5188) at android.app.Activity.finish(Activity.java:5208) at com.nononsenseapps.filepicker.AbstractFilePickerActivity.onFilesPicked(AbstractFilePickerActivity.java:165) at com.nononsenseapps.filepicker.AbstractFilePickerFragment.onClickOk(AbstractFilePickerFragment.java:309) at com.nononsenseapps.filepicker.AbstractFilePickerFragment$2.onClick(AbstractFilePickerFragment.java:196) at android.view.View.performClick(View.java:5610) at android.view.View$PerformClick.run(View.java:22265) at android.os.Handler.handleCallback(Handler.java:751) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:154) at android.app.ActivityThread.main(ActivityThread.java:6077) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:866) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:756)
Same issue here. Crash with no exception.
application getting crash
Already fixed in https://github.com/muhammed-noufal/cordova-ourcodeworld-filebrowser. Please follow the fixes title in Readme.MD https://github.com/muhammed-noufal/cordova-ourcodeworld-filebrowser#fixes
setting the target SDK system to 29 returns empty folders in a file browser like if permission was denied to access the folders but everything works in cordova-file-plugin. `function openfolder() { var permissions = cordova.plugins.permissions; permissions.requestPermission(permissions.MANAGE_EXTERNAL_STORAGE, success, error);
function error() {
console.warn('Storage permission is not turned on');
}
function success( status ) {
if( !status.checkPermission ) error();
window.OurCodeWorld.Filebrowser.filePicker.single({
success: function (data) {
if (!data.length) {
// No file selected
console.log(data);
return;
}
$("#private").val(data[0].replace("file://", ""));
},
error: function (err) {
console.log(err);
}
});
}
} `
@muhammed-noufal does your fork also handles changed related to api level 29 and 30 where there are more restrictions on saving files? I'm asking since it seems that the best approach according to google is to open a file picker to allow the user to select a location to save a file. I hope this can be archived with this plugin or a fork of it. Is this repository maintained?