[Pushed] Quick Editing in a MyCode that contains a <script> breaks editing
#1
When using Quick Edit JEditable inserts the JSON the server returns into the post upon saving before MyBB's javascript interprets it and adds only the relevant bit. If said JSON includes a <script> tag (most likely because of a MyCode), the browser will try to interpret the rest of the JSON as javascript (because </script> gets escaped as <\/script> which isn't a valid closing tag) which results in a syntax error, interrupting MyBB's javascript and showing the user a rather messed up post.

I got around it with a quick-and-dirty try catch in jeditable.min.js around $(self).html(result);, but perhaps the line could be removed entirely.
Reply


Messages In This Thread
Quick Editing in a MyCode that contains a <script> breaks editing - by Evil Eye - 2014-11-16, 08:31 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)