Page MenuHomePhabricator

All images are showing a "Sorry, the file cannot be displayed" error
Closed, InvalidPublic

Description

This is a new MultimediaViewer install on a recently updated MediaWiki (1.28.2 to 1.29). No images on the wiki are working with MultimediaViewer and they all seem to load then show the error "Sorry, the file cannot be displayed". The download option as well as view in browser are both working so I know the images themselves are fine.

Details of the error are attached to the report, which will be publicly viewable. If you are not comfortable with that, you can edit the report below and remove all the data you don't want to share.

Error details:

error: could not load image from http://tatteredwiki.org/images/6/6f/Lycus_Moss.png
URL: https://tatteredwiki.org/wiki/Lycus_Artois#/media/File:Lycus_Moss.png
user agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36
screen size: 1680x1050
canvas size: 1293x738
image size: 300x300
thumbnail size: CSS: 738x738, screen width: 664.1999824047089, real width: 800

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

I have no problems accessing http://tatteredwiki.org/images/6/6f/Lycus_Moss.png directly but it redirects to https://tatteredwiki.org/images/6/6f/Lycus_Moss.png (note the http vs https difference). So this might be a potential configuration issue?

error: could not load image from http://tatteredwiki.org/images/6/6f/Lycus_Moss.png
URL: httpS://tatteredwiki.org/wiki/Lycus_Artois#/media/File:Lycus_Moss.png

Probably the browser refusing to load an insecure asset on a secure page. That's probably not an issue with MediaViewer; your file repo might be configured incorrectly.

Hintswen claimed this task.

Found the cause, I had $wgServer set to http not https.

Aklapper changed the task status from Resolved to Invalid.Aug 11 2017, 8:44 AM

Glad you found the reason. Changing status to invalid as no issue was fixed in the code base.

Thank you guys, this solved my problem as well. However, this is probably a common issue these days, as website managers move from http to https. Wouldn't it be nice if MV/MW could give a warning pointing to this specific issue? Is an "http" $wgServer ever sensible, once MediaViewer knows that it is being served on https?

Hi, feel free to file a feature request