Img link in php code

site name : worksite3feb2023.local

What is the correct url for retrieving an image from my uploads directory?

`I've tried this: <img data-image-id="1" title="" alt="File Not Found" src="http://worksite3feb2023.local/wp-content/uploads/2023/02/2023.02-FB-pin-post-re-Greece.pdf" height="836" width="700">`
`<img data-image-id="1" title="" alt="File Not Found" src="http://worksite3feb2023.local/app/public/wp-content/uploads/2023/02/2023.02-FB-pin-post-re-Greece.pdf" height="836" width="700">`
`<img data-image-id="1" title="" alt="File Not Found" src="worksite3feb2023.local/wp-content/uploads/2023/02/2023.02-FB-pin-post-re-Greece.pdf" height="836" width="700">`
but always get "File Not Found". 
And several other iterations, none of which have worked.

Please help.

  • Does this happen for all sites in Local, or just one in particular?
    Happens on all the sites I have tried.

  • Are you able to create a new, plain WordPress site in Local and access it in a Browser?

System Details

  • Which version of Local is being used?

  • What Operating System (OS) and OS version is being used?

    • Windows 10, version 22H2
  • Attach the Local Log. See this Help Doc for instructions on how to do so:

Security Reminder

Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.

Hi @dldave

Were you able to get any of these sites working normally previously? Or have they always been like this? Did something suddenly change after an update on your machine?

As a test, can you export a site into a zip and then re-import into Local and see if the images show?

Keep us posted and we’d be happy to help further and if you’re still having trouble please share your Retrieving Local’s Log File

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.