A Few days ago i was searching the web on a tutorial on how to display wordpress posts Outside the wordpress directory. for example: Wordpress is installed at: http://www.yourdomain.com/wordpress and you want to display the wordpress posts in the members area at: http://www.yourdomain.com/members/index.php in a news block or something.
Since i didn’t find anything i thought about ways of doing this. The best thing that came up into my mind was using the MySQL database from wordpress itself. I’ve been paying with the code and i found out how to do that. And now i will explain everything to you so you can do the same when you are creating new websites.
What do you need:
You will need:
- A Wordpress Blog (Where the posts must come from)
- The Database information.
- Another Website where you want to Display the posts.
- a Good Text Editor.(Notepad++ is Recommended)
- Knowledge of HTML and PHP and maybe some CSS.
What info do you want:
First of all you need to think about which info you will need from the posts. There are multiple fields of into in the Wordpress Database like: the title, the author, the link, the Post Date, the Post Date GMT, the modification date, the modification date GMT, the comment count, the content, the post type, Etc…
There is many info so i suggest you to write down the options you want.
phpMyAdmin overview:
Login to phpMyAdmin and go to your Wordpress Database. There you should see the following:

wp_posts Table overview:
Out of the list above look for wp_posts and click on the first action button. Than you will see how it is build And what is inside the different rows. (It’s much easier to see which info is stored under which Row name when you use that action.) After you’ve clicked that you will see something similair to this:

There you see See the above, with alot more rows with info in it. All those info represents the Wordpress Postmeta which is displayed on the frontpage of the Wordpress Blog. In that way you can fully recreate the index page of the wordpress blog. Or you can fully Integrate it into an excisting CMS.
discuss this topic to forum
