kartik-v / bootstrap-fileinput

An enhanced HTML 5 file input for Bootstrap 5.x/4.x./3.x with file preview, multiple selection, and more features.
http://plugins.krajee.com/file-input
Other
5.36k stars 2.4k forks source link

PDF upload not working, shows spinning wheel, throws js errors #1870

Closed jrajamaki closed 1 week ago

jrajamaki commented 1 month ago

Prerequisites

Steps to reproduce the issue

  1. Go to demo page
  2. Upload pdf file

Expected behavior and actual behavior

When I follow those steps, I see spinning wheel without any preview and error in console: Unhandled Promise Rejection: Error: End-Of-Stream.

I was expecting, seeing a file-icon as generic preview item.

Environment

Browsers

Operating System

Libraries

Isolating the problem

Related

1822

kartik-v commented 4 weeks ago

Greetings. Cannot reproduce this issue in my environment here. Can you check if you have a local environment config conflict or PDF settings on browser preventing you doing something. Try it on different devices and systems to check the issue.

jrajamaki commented 3 weeks ago

Greetings. Cannot reproduce this issue in my environment here. Can you check if you have a local environment config conflict or PDF settings on browser preventing you doing something. Try it on different devices and systems to check the issue.

@kartik-v Hello! Tested with two other machines and also iPhone, does not work with any of them when uploading PDF file using Safari browser. For example, uploading The Foo Bird does not work.

code-knitter commented 1 week ago

Could this be related to #1862 ? The OP doesn't specify whether they use filetype.min.js, but the symptoms match. We had problems that match this description and found that the errors went away when we included filetype.js instead of filetype.min.js as described in #1862

kartik-v commented 1 week ago

Yes maybe related. The issue #1862 has a resolution. Do check with latest codebase and let know and will reopen this if issue persists.