Hi guys I am creating a admin website for editing some products but whenever i edit a product I need to input some image again to the input file since I don't know how to set up the value to input file automatically.
Is there any way I can put the image to input file without the user choosing again the image just for the input file to be filled up.
<img src="foo-image" id="image">
<input type="file" name="image" id="imageFile">
<script type="text/javascript">
$(document).ready(function()
{
var src = $('#image').attr('src');
$('#imageFile').val(src);
});
</script>
The val does not work in the input file right? Is there any other way that the input file can be filled with data automatically? and so the security will not be jeopardize.