Where are the files stored in the PhoneGap app stored on Android?

I am using PhoneGap with a file plugin. I can read and write files to the filesystem and they are saved correctly. But when I try to find these files from the native file explorer app on the tablet, or from Windows Explorer (via USB connection), I can't find any trace of these files by looking in the folder that PhoneGap claims to store these files (Tablet \ Android \ data \ com.xxx.yyy \ files) and with a search function. I have no external maps attached to my android tablet. Any ideas on how to find these files?

+3


source to share


1 answer


After looking closely at the Android documentation about storage options, I noticed that this is the intended behavior of internal storage, which is used for private applications that cannot be read by other applications accessing the filesystem.

I thought all along that external storage refers to SD cards, but instead, external storage is described as follows

Every Android compatible device supports a shared "external storage" that you can use to save files. This can be removable media (such as an SD card) or internal (non-removable) storage. Files saved in external storage are world readable and can be modified by the user when they allow USB mass storage to transfer files to computer.



which seems to be the exact behavior I was looking for. Using cordova.file.externalDataDirectory , I was able to store files on the internal filesystem (not on the SD card) and see them in the file explorer.

I think the assumption of external storage, referring only to the SD card, is not completely unreasonable since the File plugin has / as the directory for cordova.file.externalRootDirectory in the Android file system layout. That must have made me think so.

+1


source







All Articles