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

cached theme images not displayed (SVG)

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.8.7, 2.9, 3.0
    • 2.8.8, 2.9.2
    • Themes
    • MOODLE_28_STABLE, MOODLE_29_STABLE, MOODLE_30_STABLE
    • MOODLE_28_STABLE, MOODLE_29_STABLE
    • wip_MDL-50690_master
    • Hide

      1. Select the Clean theme and navigate to its location in '/theme'clean'.
      2. Create an svg image in the 'pix' folder and call it 'myimage.svg'. It can be of anything or an adaptation of an svg you already have.
      3. Alter the Clean theme 'columns3.php' file to output pix_url of 'myimage.svg' and 'anotherimage.svg', such as:

      echo '<img src='.$OUTPUT->pix_url('myimage', 'theme').'>';
      echo '<img src='.$OUTPUT->pix_url('anotherimage', 'theme').'>';
      

      4. Turn theme designer mode off.
      5. In FireFox, purge all caches - this will be fine as this will not be 'columns3.php' layout file.
      6. In IE, using the browser development tools, set the emulation to be '8' for the document mode and 'Internet Explorer 8' for the user agent string. If in doubt, see .
      7. Sill in IE, navigate to the front page as it will have the image being that 'columns3.php' is the layout file defined in 'bootstrapbase' for the 'frontpage' layout.
      8. Observe no images.
      9. Go back to FireFox and navigate to the front page.
      10. Confirm the 'myimage' image does display.
      11. Confirm that there is the file 'anotherimage.error' in the moodledata folder for the cache of the theme, e.g. 'localcache\theme\1440933977\clean\pix\theme\anotherimage.error'.

      Show
      1. Select the Clean theme and navigate to its location in '/theme'clean'. 2. Create an svg image in the 'pix' folder and call it 'myimage.svg'. It can be of anything or an adaptation of an svg you already have. 3. Alter the Clean theme 'columns3.php' file to output pix_url of 'myimage.svg' and 'anotherimage.svg', such as: echo '<img src='.$OUTPUT->pix_url('myimage', 'theme').'>'; echo '<img src='.$OUTPUT->pix_url('anotherimage', 'theme').'>'; 4. Turn theme designer mode off. 5. In FireFox, purge all caches - this will be fine as this will not be 'columns3.php' layout file. 6. In IE, using the browser development tools, set the emulation to be '8' for the document mode and 'Internet Explorer 8' for the user agent string. If in doubt, see . 7. Sill in IE, navigate to the front page as it will have the image being that 'columns3.php' is the layout file defined in 'bootstrapbase' for the 'frontpage' layout. 8. Observe no images. 9. Go back to FireFox and navigate to the front page. 10. Confirm the 'myimage' image does display. 11. Confirm that there is the file 'anotherimage.error' in the moodledata folder for the cache of the theme, e.g. 'localcache\theme\1440933977\clean\pix\theme\anotherimage.error'.

    Description

      We have an issue with where one image in a theme is not displayed.
      however other images of the same type, from the same directory, with the same permissions are displayed in the theme.

      Clearing the image cache resolves the issue - but we have had to do this more than once.

      In testing, Chrome, Safari did not exhibit the issue (with cacheing disabled on browser) but Firefox did (with caching disabled) and, clearing moodle themes fixed the issue. see missing image on top right of page.

      Attachments

        Issue Links

          Activity

            People

              gb2048 Gareth J Barnard
              pgee Peter Gee
              Mary Evans Mary Evans
              Dan Poltawski Dan Poltawski
              Marina Glancy Marina Glancy
              Huong Nguyen, Bas Brands, Mathew May, Amaia Anabitarte, Carlos Escobedo, Laurent David, Mikel Martín Corrales, Sabina Abellan, Sara Arjona (@sarjona)
              Votes:
              1 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                14/Sep/15