0

I'm getting this error for follow code:

Uncaught TypeError: $(...).fadeIn is not a function

function readURL(input) {
    if (input.files && input.files[0]) {
        var reader = new FileReader();
        reader.onload = function(e) {
            $('#imagePreview').css('background-image', 'url('+e.target.result +')');
            $('#imagePreview').hide();
            $("#imagePreview").fadeIn(650);

        }
        reader.readAsDataURL(input.files[0]);
    }
}

$('#imageUpload').change(function() {
    readURL(this);
});
atline
  • 28,355
  • 16
  • 77
  • 113

0 Answers0