I have a Wordpress site that is already published on a domain. As I wanted to update the content of some pages, I edited the local version of my website on localhost and then uploaded the files using an FTP client. However, the changes do not appear on the live site. I cleared the cache of my browser and also emptied all caches of my wordpress site using a plugin. Still no content updates showing on the website.
2 Answers
There is a difference between Wordpress files you upload on your FTP, and Wordpress "content" that is stored in your database.
For your content to be updated, you have to migrate your Wordpress database online.
Resources:
- This link explains how you can migrate your Wordpress website entirely https://www.wpexplorer.com/migrating-wordpress-website/
- For example, has stated by @WebElaine, you can use database migration plugins such as this one among others https://fr.wordpress.org/plugins/wp-migrate-db/
Also, as said in the comments, you could also copy paste your content from localhost to your live website. In order for the whole thing to be easier, try using the "preview" functionality in your editor instead of updating your localhost website.
-
Do you mean by migrating your Wordpress database online replacing the current database on cpanel by the new one, i.e. an export of the local database with all the last challenges?– HasCommented Sep 24, 2018 at 17:36
-
Basically, yes, but be sure to use a database migration plugin if you go that route. WordPress stores serialized data and the whole site can break if you just try to overwrite the database. Unless you've edited a ton of pages, it may be easier to simply copy and paste from your local editor into the live site editor. Commented Sep 24, 2018 at 17:52
-
@Has, be sure to save your old database before doing anything. I will edit my answer with ressources to help you achieve what you're trying to do. Commented Sep 25, 2018 at 5:26
You have to compare both files code, If your both online and local code matches that mean you have some other issue. If you have CDN on your sever then you have to refresh CDN-links
because php code doesn't make cache only .css
and .js
does.