2

What's the best way to pull data from Wordpress database? I think creating a plugin would be nice. Is there a tutorial out there that do the job? Or a plugin that does it? Pull content of the page via JSON/XML.

Cheers, Mickey

3 Answers 3

6

Here's the link to the plugin:

http://wordpress.org/extend/plugins/json-api/

Sign up to request clarification or add additional context in comments.

Comments

0

A generic easy way to export data from a mySQL database in XML format could be phpmyadmin.net

Comments

0

If you are looking to integrate HTML from Wordpress in a PHP-driven site, the easiest and fastest way is to include the WordPress main include, and use the native WP functions to get hold of the data.

Just one caveat from experience: Wordpress is fat. Including the wordpress header file will eat up 8-12 MB of your allocated per-script memory (usually somewhere between 16-64 MB) from the start. You may be able to steer around that, however, by loading the Wordpress data in a different script, or caching the requests (probably a good idea anyway).

WordPress also has basic built-in RSS export functionality.

3 Comments

More like Pages with the HTML formatting. Right now, I'm looking into integrating the wordpress page with my site static page for easier management. Also, this allow the marketing team to change the static content with out assistant from engineering team.
Is it possible that I create a plugin that returns the information in a JSON/XML format? The plugin basically sit between accessing the page directly via MySQl and accessing it's HTML via blog.xxx.com/?page_id=xx&view=ajax
I'm sure there are already plugins for that, no need to write it yourself. Check the repository: wordpress.org/extend/plugins

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.