6 Oct 2014

All posts from 6 Oct 2014

How to Import Posts from a Text File into WordPress

Here is a simple method that you can use to import news, posts or content from a text file into WordPress.

This script assumes the text data file has each post on a separate line with fields separated by a |. This is how most flat file news scripts store data. It also uses the php tidy extension to clean the input before inserting into the database.

If you need to import data from a different source, all you need to do is include the wp-load.php script and use wp_insert_post to insert post.

read more