This website uses cookies to remember you and improve your experience. For more info see our Privacy Policy.

  • About
  • Websites
    • Business Websites
    • Author Websites
  • SEO
  • Portfolio
    • Author Web Design
    • Business Web Design
    • Custom Graphics
    • Logos
  • Services & Pricing
    • Author Website Packages
    • Website Hosting
    • Page Speed Optimization
    • SEO
    • Local SEO
  • MyBookTable
    • MyBookTable Support
  • Contact
  • Hire Us

Mobile Menu

  • Menu
  • Skip to right header navigation
  • Skip to main content

Stormhill Media

Custom websites for every type of business

Header Right

  • About
  • Websites
    • Business Websites
    • Author Websites
  • SEO
  • Portfolio
    • Author Web Design
    • Business Web Design
    • Custom Graphics
    • Logos
  • Services & Pricing
    • Author Website Packages
    • Website Hosting
    • Page Speed Optimization
    • SEO
    • Local SEO
  • MyBookTable
    • MyBookTable Support
  • Contact
  • Hire Us

Search and Replace String

Home » Code Snippets » Search and Replace String

This is a good string to use in the sql section of phpmyadmin when replacing strings

Note that the table name is used once and the table field is used twice in each query

example for search replace in wp_posts

update wp_posts set post_content = replace(post_content,'lifetalkcafe.com','hallattorneys.com');

example in postmeta

update wp_posts set guid = replace(guid,'lifetalkcafe.com','hallattorneys.com');

Update 7/19/12
Jim found a cool script to search and replace and not break serialized strings.
https://interconnectit.com/124/search-and-replace-for-wordpress-databases/

« Previous
Next »

Site Footer

Quick Links:

  • Contact Us
  • Pricing & Services
  • Sitemap
  • Terms/Conditions
  • Privacy Policy
  • Business Websites
  • Author Websites
  • SEO Services
(903) 213-5266‬

Copyright © 2025 · Stormhill Media All Rights Reserved.
Website by Stormhill Media
Log in