Bulk Import from XML into WordPress
-
I wish to import several posts from Excel. I have a script that converts the Excel into a XML format. I have appended the output onto a WordPress XML file. I import the file into WordPress, receive email success confirmation but cannot see the posts?
More here:
https://en.forums.wordpress.com/topic/import-into-wordpress-does-not-work?replies=1#post-1129964How must I prepare each post within the XML file? What fields are mandatory? How do I populate fields like URL, and Post ID – are these not auto generated by WordPress?
The blog I need help with is: (visible only to logged in users)
-
I tagged this thread for Staff assistance. Please subscribe to it so you are notified when they respond.
-
-
Already subscribed. Hoping for an answer. Still cannot see imports from previous days.
This should be fairly straight forward as WordPress already accepts various file formats from other blog sites.
-
Your best guide to how to structure the xml file would be an actual export file with real data, such as https://wpcom-themes.svn.automattic.com/demo/theme-unit-test-data.xml
May I ask how you got these posts into Excel in the first place? Were they exported from another service? If they were, maybe it’d be better to try a straight export-import from that other service, rather than going through this intermediate Excel step. You can see the list of where we can import from, here:
-
Thanks for the response. Unfortunately this does not totally help.
I have prepared a list of posts outside of any blogging platform – basically in Notepad. I now want to bulk import these into WordPress.
I am using the WordPress XML file as my template to import these posts (from Notepad/Excel) into WordPress.
The below is an example of a post in the XML file. If I populated each field, will my import work?
Based on previous uploads, these posts do not appear.
<item>
<title>Huatulco Coastline</title>
<link>http://wpthemetestdata.wordpress.com/2008/06/10/post-format-test-gallery/img_0767/</link>
<pubDate>Fri, 15 Jul 2011 21:51:19 +0000</pubDate>
<dc:creator>chipbennett</dc:creator>
<guid isPermaLink=”false”>http://wpthemetestdata.files.wordpress.com/2008/06/img_0767.jpg</guid>
<description></description>
<content:encoded><![CDATA[Public domain via http://www.burningwell.org/gallery2/v/Landscapes/ocean/IMG_0767.JPG.html%5D%5D></content:encoded>
<excerpt:encoded><![CDATA[Coastline in Huatulco, Oaxaca, Mexico]]></excerpt:encoded>
<wp:post_id>770</wp:post_id>
<wp:post_date>2011-07-15 14:51:19</wp:post_date>
<wp:post_date_gmt>2011-07-15 21:51:19</wp:post_date_gmt>
<wp:comment_status>open</wp:comment_status>
<wp:ping_status>closed</wp:ping_status>
<wp:post_name>img_0767</wp:post_name>
<wp:status>inherit</wp:status>
<wp:post_parent>555</wp:post_parent>
<wp:menu_order>0</wp:menu_order>
<wp:post_type>attachment</wp:post_type>
<wp:post_password></wp:post_password>
<wp:is_sticky>0</wp:is_sticky>
<wp:attachment_url>http://wpthemetestdata.files.wordpress.com/2008/06/img_0767.jpg</wp:attachment_url>
<wp:postmeta>
<wp:meta_key>_wp_attachment_image_alt</wp:meta_key>
<wp:meta_value><![CDATA[Huatulco Coastline]]></wp:meta_value>
</wp:postmeta>
</item> -
How many posts do you actually have? It might actually be easier to manually publish them in WordPress rather than creating this xml file. Also, do any of your posts have images?
-
-
I think your best bet would be to actually try an import plugin on a self-hosted WordPress installation, then export it to xml from there. Or, you can look at the source of one of the plugins and see how they do it.
Otherwise, I don’t have the answer to your question, the sample xml is the best guide to how to structure the data.
-
Do you have an example of another blogging platform export file? For example, what is contained in a blogger xml file?
The frustrating part is that when I use the WordPress import tool, it says it is successful however posts do not appear and I have no idea why?
Can you supply details from the import log?
-
While you may want to sign up for a Blogger account and experiment with their export tool to see what those files contain, we still recommend working from a WordPress.org export file, as it’s the closest thing to the WordPress.com format.
Unfortunately I won’t be able to help troubleshoot further as we don’t formally support custom import formats, but I wish you the best of luck!
- The topic ‘Bulk Import from XML into WordPress’ is closed to new replies.