Reputation: 294
I have file input button( input type=file ). lets say i choose image. i want to get this image from input, modify it, and after that insert this modified image in the same file input.
Upvotes: 1
Views: 206
Reputation: 9381
HTML
<form method="post" action="upload-page.php" enctype="multipart/form-data">
<label for="filesToUpload"> Select all photo files you need.</label>
<br>
<input name="filesToUpload[]" id="filesToUpload" type="file" multiple="" />
<br><br>
</form>
jQuery (I would als use an image lib)
var input = $( "input:file");
Caman(input, function () {
this.brightness(10);
this.contrast(30);
this.sepia(60);
this.saturation(-30);
this.render();
});
Upvotes: 1