This topic has 4 replies, 3 voices, and was last updated 10 years, 2 months ago ago by Eva Kemp
Hi
Some strings are stored in javascript variable (“successfully added to your shopping cart” for example) but they are not escaped. There is no problem with the english default string but if the translated string have quote (‘) it will create a javascript syntax error.
Hello,
Please provide us with wp-admin and FTP credentials in Private Content.
Also show us screenshots where is the problem.
Regards,
Robert Hall.
I’ve already fixed the problem by changing the translated string.
The problem is in your php generated javascript code for add to cart ajax.
example
var successfullyAdded = ‘successfully added to your shopping cart’;
The variable isn’t escaped so if there is a quote in the translated string there will be a javascript syntax error.
Hello,
That’s great you’ve fixed the issue yourself.
If you have any questions feel free to ask us.
Have a nice day!
Regards,
Eva Kemp.
The issue related to '‘Escape javascript variable ?’' has been successfully resolved, and the topic is now closed for further responses