Search And Replace - REMOVE CODE

Run the below SQL command in phpMyAdmin.  Replace portion CODE_TO_SEARCH with the code you want removed.  Make sure database table prefix matches the site you are doing this on.


update wp_posts set post_content =
replace(post_content,'Text to find','text to replace with');


ANOTHER WAY BELOW:

phpMyAdmin includes a neat find-and-replace tool.

Select the table, then hit SearchFind and replace

This query took about a minute and successfully replaced several thousand instances of oldurl.ext with the newurl.ext within Column post_content

screenshot of the find-and-replace feature in phpMyAdmin

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article