File Upload preview

<input type="file" class="form-control" name="productPhoto1" onchange="preview('productPhoto1Src');" /> 

      function preview(imgSrc) {

          var fileBlob=URL.createObjectURL(event.target.files[0]);
          $("#"+imgSrc).attr('src',test123);
         
        }

Comments

Popular posts from this blog

Target class controller does not exist - Laravel 8