Instead, the string that is returned by the script, which handles the file information is C:\fakepath. WTF?!Īfter doing some research, I found this blog post, which explained:Īccording to the specifications of HTML5, a file upload control should not reveal the real local path to the file you have selected, if you manipulate its value string with JavaScript. I then checked Internet Explorer and Safari both of them were prepending " C:\fakepath" to the file name. Everything worked great until I tested the widget in Chrome and found that the value of the input node was being set to C:\fakepath\. I decided to use Dojo's widget so the "Upload" button would look just like every other button within the web application. I was recently working on a project that required providing an AJAX uploading widget to users.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |