Why is window.requestFileSystemSync undefined?
-
09-02-2021 - |
質問
I'm working with phonegap API developing in IOS. I need to retrieve the storage directory synchronously. I am trying to use window.requestFileSystemSync(LocalFileSystem.PERSISTENT,0)
but window.requestFileSystemSync
is undefined
. Any help? Thanks
解決
According to the documentation of PhoneGap v1.1.0, there is only an asynchronous method to do this called requestFileSystem
.
他のヒント
Two things come to mind:
- did you wait for phonegap device ready event?
- did you include the phonegap.js file in your html page?
The problem was that, phonegap does not define sync file system. Will have to do with async version. Thanks.
所属していません StackOverflow