This week, Support Lead, Helen Grimbly will be looking at examples of actions relating to images that can be shown in a Sitemorse assessment.
The following lists some examples of actions relating to images that can be highlighted within a Sitemorse assessment.
Inventory - Files 'by type'
- Click on any of the filetypes, and there are links to pages that show the top largest of those file types on the site. Select the URLs to view individual assets. For example selecting filetype "image/jpeg" link, will show the top 10 largest image files. If an image type is highlighted in red then the average size of that image type is over the limit 200kB and highlighted in orange it is over the limit 100kB.
This is for information only and does not affect the score.
Report - Code Quality
- file/image/size: Image file size or dimensions do not match
An example error message could be 'Image file is unexpectedly large'. This indicates the image file size is significantly larger than should be required for an image of these dimensions, and therefore is slowing down the site. This is often caused by large amounts of metadata (e.g. from a digital camera). Loading the image into an image editor and saving it again (possibilty using an option such as 'Save for Web') will usually solve the problem.
Another example error message might be along the lines of 'Image is 1000x1000 pixels but is being resized to 100x100 in the browser'. This is shown where an image is being resized (e.g. with CSS styles, or the width and height HTML attributes). This can also slow down the site.
This is a secondary Code Quality error and will affect the score.
Report - Function category
- file/image/invalid: Image file is corrupt
The image file is corrupt and could not be decoded as a valid image. Often you will find in this case that when you attempt to open the image an error message may be displayed, or the image may appear visually corrupt.
This is a priority Function error and will affect the score.
- file/image/badtype: Image file has incorrect type
A file used as an image in an HTML page is being served with a MIME type that indicates it is not an image, or that does not match the actual image file format.
An example error message could be 'File used as image but is of type 'text/html''. Here a file has been used as an image in an HTML page, but is being served with a MIME type 'text/html', that indicates it is not an image. This most commonly may indicate a server misconfiguration.
A second example is if an image file is being served with a file format JPEG, but its MIME type is image/gif, then an 'Image file has incorrect type' would be raised. This is most commonly caused by an image file being renamed (e.g. from example.jpg to example.gif).
This is a secondary Function error and will affect the score.