[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
** Changed in: mahara Status: Fix Committed = Fix Released -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: Fix Released Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
** Changed in: mahara Milestone: 1.8rc1 = 1.8.0 -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: Fix Committed Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
** Changed in: mahara Status: In Progress = Fix Committed -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: Fix Committed Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
Hi Kristina, This error happens when the returning code is the html page rather than the expected json data. The html page is not expected to be returned so obviously either a field is missing from being passed at the dropping of files (or conversly a field that is not needed is eing passed, eg a cancel button field). I have encountered this a couple of times and had added fixes for it for a bunch of scenarios. But you've discovered another one. Are you able to let me know which page and what things were enabled on the page eg license meta data, auto resizing etc and what browser you were using? I suspect there is a special combo of things happening that is causing the wrong expected results being passed back to the page. Cheers Bob -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contrib members https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: Triaged Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
** Changed in: mahara Status: Triaged = In Progress -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contrib members https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: In Progress Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
Does it send the HTML page whenever there's an error/warning on the page before it gets to the part where it would send JSON? -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contrib members https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: In Progress Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1216764] Re: JSON error when using drop zone
Not quite, the problem is there are certain form fields (which can vary depending where the fileuploader is included) that are used to cancel the file upload process. So when dropzone slurps up all the form field from it's enveloping form it gets fields like '[whatever]_cancel' that it doesn't want. In the php code there are things like if('cancel') are higher up in the hierarchy of things to do and when a cancel is encountered the normal response from pieforms is to return the page to replace itself, which is all HTML. So not an error, just normal way of things. However when the point of actually trying to upload a file is reached the response back is in JSON (either success or fail), which is what dropzone is expecting, and not the HTML one. if it gets the HTML response it throws the 'SyntaxError: JSON.parse: unexpected character' - that tells me that it is receiving a field (like cancel) that it shouldn't. These should all be ironed out now. But if the error occurs again the first thing is to do a console.log() on the form fields that filedropzone.js is sending and see if any of those are not meant to be sent on a fileupload submit. -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contrib members https://bugs.launchpad.net/bugs/1216764 Title: JSON error when using drop zone Status in Mahara ePortfolio: In Progress Bug description: latest Mahara 1.8.0dev When adding a file via drag and drop to a journal entry, I get SyntaxError: JSON.parse: unexpected character. To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1216764/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp