<html> | |
<head> | |
<script> | |
function createFile() { | |
webkitRequestFileSystem(TEMPORARY, 100, function(fs) { | |
fs.root.getFile("page.html", {create:true}, function(entry) { | |
entry.createWriter(function(writer) { | |
writer.onwrite = function() { | |
console.log(entry.toURL() + " created."); | |
}; | |
writer.write(new Blob(['<div id="innerDiv">Visible Contents</div>\n'])); | |
}); | |
}); | |
}); | |
} | |
if (window.webkitRequestFileSystem) | |
createFile(); | |
else | |
console.error("This test requires FileSystem support."); | |
</script> | |
</head> | |
</html> |