I duplicated my wordpress website from hosting to localhost using xampp. I copied the database and the web files as in the real web. The problem is that when I connect with the web in localhost the media is not being loaded.

Here is my htaccess

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /testweb/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /testweb/index.php [L]

# END WordPress

Thanks in advance

  • Is the URL-path to your "media" the same on both sites? What are the URLs/filesystem paths on live vs localhost? (It sounds like your localhost is perhaps in a subdirectory? But the live site is not? And you are using root-relative URL-paths?)
    – MrWhite
    Nov 30, 2020 at 9:42
  • @MrWhite Where can I find the media path? I think I have the url path sets properly but I'm not 100% sure
    – Jsancs
    Nov 30, 2020 at 10:02


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.