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

Base 64 images not supported in glossary


    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 3.1.6, 3.2.3
    • Glossary

      Manually creating a glossary item with a base 64 image / data url, the image is removed for no reason


      This was originally reported as being a problem with the glossary import. But in reality import is working fine, it's just we disallow base64 / data url images for no documented reason. Original report:

      I'm using moodle 3.1 , I'm assuming Marina's patches are installed.

      I find that images inserted into the glossary using the picture icon on the toolbar appear, when exported, under the FILE tag in the xml file. Those xml files can be re-imported with no problem.

      base64 images placed within the IMG tag in the html also work (and are exported) when pasted into the source code editing area in a glossary entry.

      However, base64 images in the IMG tag in an XML import, even one generated by export from moodle, will not import. The import procedure seems to throw the base64 code away.

      1. Create a new glossary and a new glossary entry
      2. Edit the source code for the definition of the glossary entry and include a image encoded in base64 in an IMG tag in the html (e.g. https://jsfiddle.net/casiano/xadvz/)
      3. Export the glossary to xml
      4. create a new glossary and import the xml you exported before. The imported entry will not include the image.

            Unassigned Unassigned
            siderob robert2018
            0 Vote for this issue
            4 Start watching this issue


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