WordPress Search And Replace All Posts
When managing a large WordPress website with a huge number of posts it will not be easy to change data inside each post. This would be a challenge especially if you want to change for example image links in all posts or replacing a certain tag in all your posts.
How To Search And Replace All WordPress Posts
- Go to your phpMyAdmin provided by your hosting provider
- Choose your desired WordPress database that you want to search and replace all its posts from the list
- This will redirect you to all WordPress tables inside your database, choose the wp_posts table.
- Press on the SQL tab from the top.
- Use the following SQL query to search and replace all your WordPress posts.
UPDATE wp_posts SET post_content=(REPLACE (post_content, 'old','new'));
Don’t forget to change the word old with the data you want search. Also change the word new with the data you want to insert in your posts.