Recently, a lot of images disappeared from pages on our website. Most pages have a large image at the top in a field called field_image. They do not display on the standard page.
However, the very same images DO display on views that reference the file_image, and they do show up as thumbnails on the edit form for nodes.
In the page source, the path to the image is simply missing, e.g., <img src=”https://ourdomain.com/sites/default/files/styles/large/public?itok=hLyOXc-x” alt=”” title=””> . When I hover over this code in Firefox’s inspector, I get a pop-up message, “Could not load the image”
If I create a new page and add a new image, it shows up on the page. If I edit a page with a missing image, and chose a different image from the media selector, it also doesn’t show.
I believe this began when we disabled the Locale module. Many pages lost their body content, but I solved that by running a SQL query to replace en with und in the language column in the field_data_body and field_revision_body tables.
I did the same replace in the field_data_field_image and field_revision_field_image tables, but that didn’t solve the image problem. I checked the files_managed table, and all image paths where there, with the format public://users/pictures/1362958964.jpg. I also checked the sites/default/files folder on the server, and the original images are all there.
I cleared the image styles cache via Drush and saw the contents of sites/default/files/styles disappear. I cleared site cache repeatedly as well as our Cloudflare cache after I tried all these things, but that never helped.
I have looked in every table I can find named anything containing the words “image” or “file”, but no others I found even have a language settings.
The files exist, the data in the tables seems right, caches have been cleared constantly, etc. etc. and after three days of trying everything I can think of or research, images are still not displaying on many critical pages.
What is going on? Does anyone have any idea?