Question: I know such questions are already answered. none of the solutions is working in my case. I've changed the links in the database using all possible methods I found on the internet. My site is not loading images because it's picking the localhost path after migrating it to the server. It doesn't seem to be a database issue. because I checked my database multiple times.
here is the screenshot of the errors.
[![enter image description here](https://i.stack.imgur.com/CQ9tF.jpg)](https://i.stack.imgur.com/CQ9tF.jpg)

Answer: 
Dump database to SQL file, open it with text editor and check (with search) if there are no old site's links there.
These are old links that exist in your sql db , You should search and replace all these links with the new urls matching to your website , I Prefer using SEARCH-REPLACE-DB-MASTER tool , But don't forget to delete it right after its usage , Plus also you may find some broken links "posts/pages" , Don't worry , This just need you to open your dashboard "Settings - Permalinks - Save" so that you reset your permalinks , Here is the tool and its documentation . <https://interconnectit.com/products/search-and-replace-for-wordpress-databases/>