Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-46746

Remove excessive filtering of non-ASCII charcters

XMLWordPrintable

      Atto has a cleanHTML() function (run both when the text is saved, and when using Undo) that replaces certain non-ASCII characters with ASCII renderings, e.g.

      1. "½" -> "1/2"
      2. "©" -> "(c)"
      3. "…" -> "..."

      This was added in MDL-43857, from a third party filtering script from around 2006 - when presumably document encodings and UTF-8 handling was less robust.

      As UTF-8 handling is better now than in 2006, and the ASCII rendeerings are quite ugly, filtering of these extended characters should be removed.

      Additionally - given that TinyMCE doesn't do this filtering - this could be considered a regression in functionality resulting from making Atto the default editor.

      Replication steps:

      1. Create Page activity.
      2. Enter some text including extended charcters "½©…" - e.g. this line.
      3. Make some of the text bold.
      4. Use the Undo function to remove the bold formatting.

      Expected results: No change to the extended characters.

      Actual results: The extended characters are replaced with ASCII renditions.

      Forum discussion: https://moodle.org/mod/forum/discuss.php?d=265622

            emerrill Eric Merrill
            balchd Dave Balch
            Damyon Wiese Damyon Wiese
            Dan Poltawski Dan Poltawski
            Adrian Greeve Adrian Greeve
            Votes:
            14 Vote for this issue
            Watchers:
            16 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.