I have a Base64 image string, i need to set the value of an input type file field, i have no control of the server side, or of the site, so it has to be done like this.
need to set the value of an input type file field, i have no control of the server side, or of the site, so it has to be done like this.
Is this possible?
No, it is not possible to "set" the FileList object , or File
object of an input
element
An object of this type is returned by the files property of the HTML
element; this lets you access the list of files selected with the
element.
var file = document.getElementById('fileItem').files[0];
Method overview
File item(index);
Properties
Attribute Type Description
length integer A read-only value indicating the number of files in the list.