Site logo

Archived topic

Pictures not showing even though file path works

3 replies · Started by Charles on October 15, 2022

Viewing posts 1–4 of 4

Hi,

Until yesterday I had not thought about file paths in WordPress or Generatepress. However, when I moved one site from a 2012 Windows Server to my new Ubuntu server I noticed some of the photos did not display. Some do most do not.
https://dutton-white.com/commissions/

I can see the file paths in view source, for the main picture they look right.

`<figure class="wp-block-image size-full"><img width="600" height="283"
src="https://dutton-white.com/wp-content/uploads/commissions/porsche-commission.jpg" alt=""
class="wp-image-123" srcset="https://dutton-white.com/wp-content/uploads/porsche-commission.jpg 600w,
https://dutton-white.com/wp-content/uploads/porsche-commission-300x142.jpg 300w"
sizes="(max-width: 600px) 100vw, 600px" />
</figure>

If I put the file path in a browser
https://dutton-white.com/wp-content/uploads/commissions/porsche-commission.jpg
I see the graphic
Yet the picture is not showing in the page.

In edit mode I can see the picture.

I can see the two alternatives in the srcset they are in the folder commissions along with the full size option.
However, what seems to have happened is the smaller versions of the picture do not have the correct file path to the folder in this case commissions.

Any suggestions as to how I can fix the folder file path for the srcset pictures?

Many thanks

Charles

Hi there,

the Theme has no control over those URLs, we don't interfere with permalinks.
It seems that the migration did not respect the custom folder structure in the URL.

How was the migration performed ?

Hi David,
I tried moving the database from the original server to the new server again but still got the same result.
I tried removing the class="wp-image-***" code from each picture which had the result of making the picture display – not sure if this is a fatal thing one should not do but alas the website owner died a few months ago.
I will see how I go moving some more websites.
I suspect that the plugin which I used to create the additional folder structure was in some ways responsible for the file path corruption. I will try and guard against a plugin like that malfunctioning in the future.
Thanks for taking a look.
Kind regards

Charles

Yeah it may be worth checking with that plugin author to see if others have experience similar issues.

Sorry we couldn't be of much help

This archived topic is closed to new replies.