[Koha-bugs] [Bug 8942] Translation process breaks javascript in calendar.inc

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Oct 19 14:19:41 CEST 2012


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8942

Kyle M Hall <kyle at bywatersolutions.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #12908|0                           |1
        is obsolete|                            |

--- Comment #7 from Kyle M Hall <kyle at bywatersolutions.com> ---
Created attachment 12935
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12935&action=edit
[SIGNED-OFF] Bug 8942 Fix translation of JS strings containing simple/double
quote

With this patch, translated strings containing simple or double quotes
are transformed to their HTML entities counterpart. This prevent
breaking JavaScript strings.

For example:

  Today, translated in French is Aujourd'hui. And so this JS line:

    var m = _('Today');

  become in French:

    var m = _('Aujourd'hui');

  It breaks the whole JS code. With this patch:

    var m = _('Ajourd&apos;hui');

Same issue with ", and JS strings like "foo".

Signed-off-by: Kyle M Hall <kyle at bywatersolutions.com>

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.


More information about the Koha-bugs mailing list