Swapping Out Real Emails On A Page For Screen Shots

Recently, I needed to put together some screen shots of output from a custom ads plugin I was working on. During the testing, I had several user accounts that all had various real email addresses of mine. I obviously didn’t want these in the demo shots, but I didn’t really want to go edit all the accounts or have to doctor the images to blur the details. What to do?

Thankfully this was on a WordPress site so jQuery was available. By dropping a couple of lines of JS in the console, I was able to change every instance of the real address on the page with bogus info. This let me take my screen shots without worrying about anything.

It couldn’t have been easier to do. The addresses were all in anchor tags within table cells. This made the selector easy to specify and the task took just a couple of minutes.


jQuery("td a:contains('user@real-domain.com')").text('fake.name@bogus-domain.com');

Hope this helps somebody else.

Bill Wheeler

I'm a veteran PHP/MySQL Developer and SysAdmin with JavaScript, jQuery, HTML/CSS, etc. added in for good measure.

Bill Wheeler wrote 5 posts

Post navigation