Development

#9986 (problem with \\' into a translated javascript string written in php)

You must first sign up to be able to contribute.

Ticket #9986 (new defect)

Opened 1 year ago

problem with \\' into a translated javascript string written in php

Reported by: emmanuel Assigned to: fabien
Priority: major Milestone:
Component: i18n Version: 1.4.16
Keywords: javascript translation quote Cc:
Qualification: Unreviewed

Description

into a template i've got a javacript code:

if (i == 1)

code_html += '<?php echo ("Couleur d\\'origine : ")?>';

but in the message.xml for traduction, there is:

<trans-unit id="2">

<source>Couleur d\\'origine : </source> <target/>

</trans-unit>

the translation doesn't works ! this one works (i delete a \):

<trans-unit id="2">

<source>Couleur d\'origine : </source> <target/>

</trans-unit>

but when i rescanne the page to find sentences to translate:

php symfony i18n:extract frontend de --auto-save --auto-delete

the script delete the good one and add the bad one