jquery-filedrop icon indicating copy to clipboard operation
jquery-filedrop copied to clipboard

jQuery(...).filedrop is not a function with jQuery 3.1.1

Open jmchauv opened this issue 8 years ago • 10 comments

Is there a fix for this? I am upgrading from jQuery 1.7.2 to 3.1.1 and am receiving this error:

jQuery(...).filedrop is not a function

jmchauv avatar Jan 16 '17 16:01 jmchauv

Found that problem too. The solution is:

  1. remove jQuery.event.props.push("dataTransfer");
  2. change e.dataTransfer to e.originalEvent.dataTransfer

good luck

upd: fixed in new file version already (v. is still 0.1.0)

Dolgovec avatar May 29 '17 06:05 Dolgovec

I am having the same issue with jQuery 3.2.1 have tried to the fix above but its causing other

rickdatel avatar Dec 11 '17 13:12 rickdatel

I am also having the same issue with JQuery 3.2.1. Tried the above fix, but now it generate another error "Syntax error, unrecognized expression: #"

mvpkenlin avatar May 30 '18 05:05 mvpkenlin

Hello I've tried this fix above as well, does any one have an update, I've been searching for a couple hours now, I'm working on a MVC 5, jquery-3.3.1 project, and I like the FileDrop.js function for its simplicity.

ShawnJ013 avatar Oct 02 '18 17:10 ShawnJ013

Using JQuery 3.3.1 and tried the fix above and get

"Syntax error, unrecognized expression: #"

Any ideas?

alexd612 avatar Nov 19 '18 19:11 alexd612

Add this reference then all will become good in the world.... <script src="https://code.jquery.com/jquery-migrate-3.0.1.js"></script>

carlblanchard avatar Nov 24 '18 20:11 carlblanchard

im also facing this issue. The solution "* remove jQuery.event.props.push("dataTransfer");

  • change e.dataTransfer to e.originalEvent.dataTransfer"

also gives the next error: "Syntax error, unrecognized expression: #".

Adding the reference to jquery-migrate doesnt solve it either.

Please advise.

allac00 avatar Feb 13 '19 12:02 allac00

Hey i think i ended up just using a file browse button. I could never get the drop box working properly.

On Wed, Feb 13, 2019, 7:26 AM allac00 <[email protected] wrote:

im also facing this issue. The solution "* remove jQuery.event.props.push("dataTransfer");

  • change e.dataTransfer to e.originalEvent.dataTransfer"

also gives the next error: "Syntax error, unrecognized expression: #".

Adding the reference to jquery-migrate doesnt solve it either.

Please advise.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/weixiyen/jquery-filedrop/issues/185#issuecomment-463180753, or mute the thread https://github.com/notifications/unsubscribe-auth/ApNcxnS0KXGCHaNdgV5ZqSD5hCVvscyHks5vNARcgaJpZM4Lkw-6 .

alexd612 avatar Feb 13 '19 18:02 alexd612

#186 fixes this issue if you're in a pinch.

joshuafredrickson avatar Feb 24 '19 18:02 joshuafredrickson

Hi, i have made a fork and submit a pull request with solution to this error. The error is when opt fallback_id is not set, then in filedrop.js the line 100 fail because $('#') is not a valid identifier Solutions is move these block into " if ( opts.fallback_dropzoneClick === true )" or setting the option 'fallback_id' to any existing element or simply check if fallback_id is set

:)

Nailuj2000 avatar Sep 12 '20 09:09 Nailuj2000