Reputation: 4315
I am developing an iOS App for a blog. I managed to parse the posts and their content using the RSS feed, that Wordpress provides.
Now, i want to get an RSS feed of categories, so when an user selects a category, to display that category's posts. According to the Wordpress codex, there is a way to retrieve all the posts from a category, but how can i get a list of categories, maybe with an identifier or something so i can get all the posts based on that.
Thanks in advance.
Upvotes: 1
Views: 1252
Reputation: 976
I know I'm late to the party, but any custom theme dev's out there that are looking for a PHP way to easily do the same... this worked great for me:
href="<?php bloginfo('rss_url'); ?><?php echo('?cat=XXX'); ?>"
Where "XXX" is the category ID for the respective category you wish to pull in.
Upvotes: 0
Reputation: 5031
Why not try making use of get_categories()? You could parse that into an xml feed, and expose it at http://yoursite.com/category-rss/
for your app.
Upvotes: 2