Click here to Skip to main content
15,898,924 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
give full code of readind and writing file using javascript by client side
Posted

1 solution

If your JavaScript code could access local files of the visitor to your site, it would be a huge security problem. That's why no browsers would allow it.

But there are couple of ways to achievde it with users permission:
1. Using JavaScript extensions (runs from JavaScript Editor), or
2. Using a web page and ActiveX objects (Internet Explorer only)

Using ActiveX objects gives you many possibilities, but there are two distinct disadvantages:

a. You need a web page to run your JavaScript, and
b. ActiveX objects only work with the Internet Explorer browser.

Here is the full details of how you can get it done with sample code.
How to read and write files in JavaScript[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900