Whether you run a WordPress community with 1,000 members or a WooCommerce store with 100,000 orders, sometimes for testing you want to change all the account emails to something like “email@example.com”
After all, you don’t want to accidentally send a test email to all those users!
How to Change All WordPress User Emails to firstname.lastname@example.org
Run the following SQL query on the database for recent versions of phpMyAdmin:
UPDATE `wp_users` SET `email@example.com'
Run the following SQL query on the database for earlier versions of phpMyAdmin:
UPDATE wp_users SET firstname.lastname@example.org'
This will set all WordPress users’ email addresses to “email@example.com”.
How To Update All WooCommerce Order Email Addresses to firstname.lastname@example.org
If you are using WooCommerce, do the above and THEN do this for newer versions of phpMyAdmin:
UPDATE `wp_usermeta` SET `meta_value` = 'email@example.com' WHERE `meta_key` = 'billing_email'
If you are using WooCommerce, do the above and THEN do this for older versions of phpMyAdmin:
UPDATE wp_usermeta SET meta_value = 'firstname.lastname@example.org' WHERE meta_key = 'billing_email'
Pretty nifty, eh?
More posts from themightymo.com
How to install a Cloudflare SSL certificate on Siteground
Hey there! In this video, I’ll show you how to install a Cloudflare SSL certificate on your SiteGround website. I’ve noticed that Let’s Encrypt sometimes doesn’t renew properly due to conflicts with Cloudflare, so this is a great solution. We’ll use TCwebsecurity.com as the guinea pig. I’ll walk you through the process step-by-step. Once we…
How to Download a Website from Wayback Machine
Today I ran into an issue where a bunch of website files were deleted off the server, and I was called upon to restore the old files. After first pursuing other options (e.g. backups), I landed on Wayback Machine as the next best choice. Thankfully, there’s a handy command line tool for downloading any site…
My WordPress Maintenance Process
A few quick things: My WordPress Maintenance Process Demo, Part 1 Transcript: You’ll see immediately after logging in, you see the 11 updates needed as well as some messages. I’m just gonna quickly read. It looks like this. I don’t need to worry about. Are you enjoying Monster Insights? Not really <laugh>. What’s to enjoy…