문제

I want to make some file operation using Javascript or jQuery for Cross Browser like:

File create
File write
File read
Update
Remove/delete

Is it possible to do above stuffs? If possible, from where I can get the idea? Please suggest me.In any end (client/server) how can it be done?i asked this just for know!

도움이 되었습니까?

해결책

No you can't do such type of operation on browser.

You need Server Side JavaScript Node.js.

There are lot of details in Filesystem

Write a file example

var fs = require('fs');
fs.writeFile("yourpath", "Hello", function(err) {
    if(err) {
        console.log(err);
    } else {
        console.log("The file was saved!");
    }
}); 

다른 팁

No you cannot do this kind of operations on all browsers.

The functionality you are looking for can be accomplished using ActiveX in Internet Explorer only

Html 5's File Api also exist but has many limitations:

Items in one application’s Sandbox are invisible to others.

Items in the Sandbox is invisible to other types of web browsers. For example, a Sandbox created in Google Chrome is invisible to other non-Chrome browsers.

Items in the Sandbox is invisible to non-browser programs.

For more info on this visit this

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top