Jump to content

Simple quote in translation not escaped for javascript var


Cawet

Recommended Posts

In prestashop : Simple quote in translation is not escaped for javascript var, making all js on page proken.

 

exemple :

  Media::addJsDef([

'selectstate' => $this->module->l('Select State', 'sellerrequest'),

]);

 

french translation :

"Sélectionner l'État"

 

resulting inline code :

var selectstate = 'Sélectionner l'État ';

 

Trying to replace tranlsation by "Sélectionner l\'État", but the escape is remove after saving.

 

 

Prestashop version 1.6.1.13.

 

It is the same for you ?

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...