MyThinkPond

On Java, Python, Groovy, Grails, Spring, Node.js, Linux, Arduino, ARM, Embedded Devices & Web

Archive for the ‘WordPress’ Category

WordPress Export Import Site Escaped Character Challenges – ”

Posted by Venkatt Guhesan on October 30, 2012

When you export a WordPress site and import the site into a new WordPress site you will notice that a few HTML entities that are not allowed in an XML output got escaped. In simple terms, you will see a lot of " and if you use a Mac OSx system, your will see – “ and ” displayed as content in your blog pages.

Well here’s a way to correct them.

1. Identify a list of these escaped XML entities using the HTML Entities Table. For most folks it would be just "

2. Within your hosting environment, find out how to get to a MySQL query window to run your SQL commands.

3. Backup your current database. And know how to restore it. (I am not liable).

4. Run the following SQL command:


UPDATE wp_posts
SET post_content= REPLACE(post_content, '"', '"');
UPDATE wp_posts
SET post_content=REPLACE(post_content, '&lt;', '<');
UPDATE wp_posts
SET post_content=REPLACE(post_content, '&gt;', '>');

Here in this example, I’m replacing all occurrences of &amp;quot; with a double-quote. Now load up a sample blog article and verify that the issue is resolved.

Repeat steps-4 for each escaped HTML entity.

Now you’re all set to begin blogging with your newly imported WordPress blog. Happy Blogging!

Posted in General, WordPress | Tagged: , , , , | Leave a Comment »