Below are four examples of images randomly taken from the Net, two are displaying properly with in custom theme template using <img src="<?php echo $block->getViewFileUrl('publicite1.jpg'); ?>" />
but two others won't be displayed by Magento:
Images not being displayed:
- http://www.webdo.tn/wp-content/uploads/2015/09/publicite1.jpg
- http://fr.learnlayout.com/images/logo.png
The value in the browser developer tool inspector for these images is <img src="http://www.mywebsite.com/pub/static/version1510292523/frontend/Myvendor/mytheme/en_US/images/publicite1.jpg" style="display: none !important;">
Images being displayed:
What is the problem with these images not being displayed ?
ADDENDUM:
I noticed that it worked after changing the name of one of the images in web/images
and in its path in the phtml file, but didn't work again when renaming it to the original name.
It seems the problem is coming from Chrome and Firefox, these images are displaying fine with Safari and Vivaldi. But cleaning the cache of Chrome and Firefox doesn't help. Maybe there's a deep cleaning function somewhere in these browsers ?
web/images
folder ?style="display: none !important;"
from<img>