Find Jobs
Hire Freelancers

Read and Write local files in a local web browser page with a plugin and javascript

$30-99 USD

已取消
已发布将近 13 年前

$30-99 USD

货到付款
A simple, small cross-browser plugin to enable the user to write to a local file and read from a local file by clicking buttons. The information to be saved in the file comes from javascript, and when the file is read, the output is to javascript. ## Deliverables fileio plugin specification: I think I have researched enough to establish that the requirement of this project is for a plugin. How it works: A .htm file is saved locally on a computer (e.g. [login to view URL]). It can have any name, and can be saved in any location. Saving a file. * -The file [login to view URL] is opened in a browser. The user is able to click a button on the page, and a string specified in javascript is saved to a file name that is also specified within the javascript in much the same way as a file is downloaded from a web page. Both the file name and file contents need to be dynamic e.g. they might contain a random number generated by the javascript when the user loads the page. The javascript side of this project is complete. * -If the file name already exists, the user should be asked if they want to overwrite the file. This is not critically important, and for simplicity and future compatibility, the plugin should offer whatever the browser's default action is when downloading a file where the name already exists e.g. downloadedfile(1).txt Reading a file. * -On clicking an HTML button (e.g. Browse...) The user of [login to view URL] should also be able to read a local file into a 1 dimensional javascript array where each line in the file is an element in the array and element zero is the full file path. The browse dialog should work in much the same way as attaching a file to an email works. Notes * -For security, the plugin should not work from an online page, only a local one. My file is saved at: file:///C:/Users/user/Desktop/[login to view URL] but it should work for a local file with any name, saved in any local folder. * -I understand that the ability to read and write files to the user's system from within is a security risk, but it adds greatly to the usability of this project. * -I would like the plugin to work on Windows, Mac, Linux and on Chrome, Firefox, IE and Safari, but I would settle for Windows and Chrome, Firefox and IE. * -I think the coding elements of the plugin should be relativly straightforward. There is an application called Firebreath where cross browser and OS plugins can be developed. I understand the plugin type is an NPAPI plugin, though that might be different for Internet Explorer. * -I don't know what format the plugin would have. If it was a single .exe file that could be launched on and OS for any browser, great. If a different file was created for each OS/browser environment, that's not a problem. * -I would like to examine all source code and know what system the plugin was developed in. Below is an example of the code contained within [login to view URL] : <pre> <html> <head> <title>Page</title> <script type="text/javascript"> function savefile() { var variable1=[login to view URL]([login to view URL]()*10+1); var variable2=[login to view URL]([login to view URL]()*10+1); var savefilename="page"+variable1+".txt"; var savefilecontents="this is the contents of the file. It can be any text, and dynamically generated."+variable2; //Code communicating with the plugin goes here. //When the user clicks the Save button the savefile function is called alert("Saved: "+savefilename); } function loadfile() { var loadfilepath=""; var loadfilecontents=""; //Code communicating with the plugin goes here. //File path and file contents are saved to a 1 dimensional array where element [0] is the file path and the remaining elements are the lines of the file, or two separate variables as shown here. alert("Loaded: "+loadfilepath+" containing: "+loadfilecontents); } </script> </head> <body> <button onclick="savefile();">Save</button> <br /> <input type="file" onclick="loadfile();"></input> </body> </html> </pre>
项目 ID: 3377374

关于此项目

2提案
远程项目
活跃13 年前

想赚点钱吗?

在Freelancer上竞价的好处

设定您的预算和时间范围
为您的工作获得报酬
简要概述您的提案
免费注册和竞标工作
2威客以平均价$84 USD来参与此工作竞价
用户头像
See private message.
$84.15 USD 在14天之内
5.0 (56条评论)
5.7
5.7
用户头像
See private message.
$84.15 USD 在14天之内
0.0 (0条评论)
0.0
0.0

关于客户

UNITED KINGDOM的国旗
Tunbridge Wells, United Kingdom
5.0
6
付款方式已验证
会员自10月 7, 2008起

客户认证

谢谢!我们已通过电子邮件向您发送了索取免费积分的链接。
发送电子邮件时出现问题。请再试一次。
已注册用户 发布工作总数
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
加载预览
授予地理位置权限。
您的登录会话已过期而且您已经登出,请再次登录。