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

Remove excessive filtering of non-ASCII charcters

    XMLWordPrintable

    Details

      Description

      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

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              emerrill Eric Merrill
              Reporter:
              balchd Dave Balch
              Peer reviewer:
              Damyon Wiese
              Integrator:
              Dan Poltawski
              Tester:
              Adrian Greeve
              Participants:
              Component watchers:
              Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              14 Vote for this issue
              Watchers:
              16 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                11/May/15