Replace Content In Your Wordpress Using SQL

Like we all know, we can use SQL to replace or remove some content in our Wordpress using phpMyAdmin, on this i will show you How To Replace/Remove Content On Your Wordpress Using SQL. On this trick you can access through phpMyAdmin on your server or using plugin Wp-DBManager and you can direct access through Wordpress Admin panel.



After you install DB Manager or logging into phpMyAdmin, go to run SQL interface and do this code:

UPDATE wp_posts SET post_content = REPLACE ( post_content, 'nofollow ', '' );

On this sample, you will remove all content with nofollow on your post content. Please not you can multiple SQL query too by using this method:

UPDATE wp_posts SET post_content = REPLACE ( post_content, 'nofollow ', '' );
UPDATE wp_posts SET post_content = REPLACE ( post_content, ' nofollow', '' );

UPDATE wp_posts SET post_content = REPLACE ( post_content, ' rel="nofollow"', '' );

This method does the same thing but multiple queries are executed at the same time. You can tweak this code what ever you want, like replace wordpress.org with funisonline.blogspot.com, so all your content with url's to wordpress.org will be replaced into funisonline.blogspot.com using this method.

UPDATE wp_posts SET post_content = REPLACE ( post_content, 'wordpress.org ', 'funisonline.blogspot.com' );

That's all, i hope our tutorial replace or remove content on your Wordpress using SQL worked for you.
Post a Comment (0)
Previous Post Next Post