Minimee
ExpressionEngine 2
Back to this add-on's main page
View Other Add-ons From John D. Wells
Fatal error: Uncaught exception ‘JSMin_UnterminatedStringException’
Bug Report
Amity Web
|
Posted: 28 June 2013 05:57 AM |
|
|
|
Been using Minimee for a long time, its always worked fine.
Very recently a customer started to get 500 Errors on some NEW entries he has created.
Enabling debug=1 in the EE index.php file shows this:
Fatal error: Uncaught exception ‘JSMin_UnterminatedStringException’ with message ‘JSMin: Unterminated String at byte 630: ‘;’ in /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/JSMin.php:192 Stack trace: #0 /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/JSMin.php(143): JSMin->action(1) #1 /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/JSMin.php(83): JSMin->min() #2 [internal function]: JSMin::minify(’?????var google…’) #3 /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/Minify/HTML.php(227): call_user_func(Array, ‘?????var google…’) #4 [internal function]: Minify_HTML->_removeScriptCB(Array) #5 /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/Minify/HTML.php(96): preg_replace_callback(’/(\s*)[removed]...’) #6 /home/cheaptyr/public_html/system389jk29djsk2/expressionengi in /home/cheaptyr/public_html/system389jk29djsk2/expressionengine/third_party/minimee/libraries/JSMin.php on line 192
As stated, its just on some new entries.
I upgraded to version 2.1.8 and still get the same issue.
Turning off JS minification fixes it. BUT we have a Google map on the page this loads, and this is not showing on the pages that display this error. So I wonder if its due to minifying a Google Map that is not working for some reason?
|
|
|
Amity Web
|
Posted: 28 June 2013 06:33 AM |
# 1
|
|
|
The issues seems to be with the GMap plugin to render maps. If an apostrophe is used in the address it breaks, the map is not displayed. Then Minimee cant handle the broken map and shows this error.
|
|
|
John D Wells
|
Posted: 02 July 2013 11:50 AM |
# 2
|
|
Developer
|
Hi Amity,
Sorry for the slow reply, I’m on holiday right now so with limited access to email etc.
Would you be able to copy and paste an example of how you’re using Minimee? In case you are in fact minifying any Google Map libraries coming from Google’s CDN, I would recommend to not do that - the minification may rewrite variable names and break functionality.
Curious though about the apostrophe - again some examples illustrating this would be helpful, so I may try to reproduce on my end.
Cheers,
John
|
|
|
Jelle Dijkstra
|
Posted: 19 March 2015 05:56 AM |
# 3
|
|
|
I’m currently experiencing the same issue. Is there a way to fix this? i/m using 2.1.13
|
|
|
John D Wells
|
Posted: 19 March 2015 06:11 AM |
# 4
|
|
Developer
|
Hi Jelle,
Could you paste in an example of how you’re using Minimee?
In case Minimee is choking on one particular JS file, you can turn off JS combination, this will still compress every JS file but should try to save them individually - this might help track down which file in particular is causing you trouble.
Cheers,
John
|
|
|
Jelle Dijkstra
|
Posted: 19 March 2015 06:28 AM |
# 5
|
|
|
To make the error go away, i have to uncheck the minify js in the extention settings. When i do that no errors.
I am using google maps. However, i do not minimee any of those script tags.
When i have minifying js turned on i get the error on the same pages that do not load my google map when the minify js setting is turned off
{exp:minimee:js} [removed][removed] [removed][removed] [removed][removed] [removed][removed] [removed][removed] [removed][removed] [removed][removed] [removed][removed] [removed][removed] {/exp:minimee:js}
|
|
|
John D Wells
|
Posted: 19 March 2015 07:35 AM |
# 6
|
|
Developer
|
Can you use pastebin or otherwise try to sanitise that snippet? It’s been [removed] by devotee.
Would you also be willing to zip up and attach the JS files you’re using? I can then test these individually and track it down.
Cheers,
John
|
|
|