2
我想在PhoneGap的(IOS)刪除圖像,所以我呼籲:entry.remove(成功,失敗)調用成功,但不刪除圖像
window.resolveLocalFileSystemURI(imageURI, ok, no);
這個調用OK功能
function ok(entry) {
alert("Deleting: " + entry.name);
entry.remove();
}
所以一切都按計劃進行,但我的圖像仍然顯示在我的圖書館。我究竟做錯了什麼?
完整的源:
window.resolveLocalFileSystemURI(imageURI, ok, no);
function ok(entry) {
alert("Delete file entry: " + entry.name);
entry.remove(pictureRemoved, notRemoved);
}
function pictureRemoved(){
alert('removed');
}
function notRemoved(){
alert('not Removed');
}
function no(error) { alert
("resolveFileSystemURI failed: " + error.code); }
舉個完整的例子 – Patel