Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Yes, it can be done. </p> <p>One way is to use the xml-rpc api. Wordpress blogs have an xml-rpc api(which you need to enable on the Wordpress blog under "Settings - Writing"). You will also need to create a user on the blog, which you give at least read access, and for which you include the credentials in your app. From then on, you can do xml-rpc calls to your Wordpress blog(s).</p> <p>If using this xml-rpc api is an option, take a look at this Java lib: <a href="http://code.google.com/p/wordpress-java/">http://code.google.com/p/wordpress-java/</a></p> <p>You can get the blogposts using this lib like this:</p> <pre><code>String username = args[0]; String password = args[1]; String xmlRpcUrl = args[2]; Wordpress wp = new Wordpress(username, password, xmlRpcUrl); List&lt;Page&gt; recentPosts = wp.getRecentPosts(10); </code></pre> <p>Also, the official Wordpress Android app is open source. Instructions to get it are at: <a href="http://android.wordpress.org/development/">http://android.wordpress.org/development/</a> You could use this source code as a starting point and adapt it to your needs.</p> <p>Note that you can only use the xml-rpc api when you have a user with read access. If you do not have the credentials of a user with read access, you can't get the posts using the xml-rpc api. Fetching the rss feed and parsing the rss feed with some java lib would probably be your best bet then(check <a href="http://www.vogella.com/articles/RSSFeed/article.html">http://www.vogella.com/articles/RSSFeed/article.html</a> on how to read an rss feed using Java).</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload