Images not displaying in frontend but available in backoffice
p
We've got a problem that the images are not displaying in the frontend but are available in the backoffice so the file is there and you can view it. In the console there is the following error. An unhandled exception has occurred while executing the request. SixLabors.ImageSharp.UnknownImageFormatException: Image cannot be loaded. Available decoders: - TIFF : TiffDecoder - BMP : BmpDecoder - TGA : TgaDecoder - QOI : QoiDecoder - GIF : GifDecoder - PBM : PbmDecoder - Webp : WebpDecoder - JPEG : JpegDecoder - PNG : PngDecoder I think it has something todo with the cache because we usynced these images from staging to localhost
d
uSync will sync all the references in the media library from one instance of Umbraco to another, but doesn't copy the physical files. I assume you have validated that the files exist in the media folder (or cloud storage)?
p
@DortL7L7L7 the file preview works in the backoffice so i think the physical files should also be there. but i'll have a look. How do u sync the physical files?
d
Copy/paste 😦
s
Is your image of one of the listed formats that ImageSharp supports?
d
You can also clear the various Umbraco caches from Settings, if you really think that is the issue
p
@User it is a jpg could this be a problem because its no jpeg?
d
No. image/jpeg handles either jpg or jpeg files
p
hmmm i dont get it then
as you can see the image is available here
d
Have you tried outputting the url that ImageSharp thinks the image is supposed to be coming from? Then loading that url directly in the browser?
Certainly looks like the image is there 😄
p
hmm the image cropurl is null there ill have a look into it where the problem is and'll tell you
s
Must be something weird in the encoding of the file. ImageSharp reads headers from the file to determine the format, and something in there must be "wrong", but not wrong enough for the browser to fail showing the image. Try re-saving it from an image editor, and see if that helps.
d
@PascalEugster Did you get this sorted?
p
@DortL7L7L7 I didn't quite get it. It seems to be a caching problem, since deleting the local cache folders worked. But refreshing it over umbraco itself didnt. Its really weird, maybee i did something wrong. But i'll have an eye on it in the future. if i figure something out i'll let you know!
Thanks @DortL7L7L7 and @skttl for your help folks!!
118 Views