Jquery Image to Base64 Convert ,For Servier side upload
Thursday, April 26, 2018 Category : Jquery 0
var file1;
if (document.getElementById("inputFile").files.length > 0) {
file1 = document.getElementById("inputFile").files[0];
var reader = new FileReader();
reader.readAsDataURL(file1);
var image;
reader.onloadend = function (e) {
var Image64= e.target.result;
// post to server
}
}