Wordpress categories list RSS feed - php

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.

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.

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.

Related

How to use feed to display recent 3 posts from WordPress to non-Wodpress site?

I want to display recent 3 posts from WordPress blog to Non-Wodpress site using feed ?
I just want to make a block on my HTML in another site.
the block shows last 3 posts from my blog.
how I can do it with feed?
my site feed is :
https://asool.org/blog/feed
A good way to get data like that is to query the WP Rest API and get the desired data via JSON. For your website the rest endpoint with the latest 3 posts would be https://asool.org/blog/wp-json/wp/v2/posts?per_page=3

Is it possible to make one post category unsearchable in wordpress?

I have a category that I don't want to be searchable in my wordpress site. The category is for employees only. I have created a username and password on my site for them to access and also a simple rss feed web app to view it from their phones, but I need it to not be searchable on search engines. I have installed Wordpress Access Areas, but if I set the view post to "Logged in Users" the post disappears from the RSS feed.
Is there a code I can use to make sure that the posts aren't searchable but still able to show up in an rss feed for my employees?
Simply Exclude plugin will do what you are looking for :) You can filter which posts, categories, tags and other taxonomies are available to WordPress search.

Show Posts from Another WordPress Site

I have 3 WordPress sites. I want to be able to add posts to one of the sites, and show some of the posts on the other two based on their categories.
E.g. site one has all posts,
site two shows posts from site one with category 'site2'
Easiest thing to do is use RSS. See FeedWordPress | simple and flexible Atom/RSS syndication for WordPress and Developer's Guide - Google AJAX Feed API - Google Code and Magpie RSS - PHP RSS Parser for different ways to implement RSS feeds as links or import posts themselves.

Wordpress display category posts on different page

I have a posts category setup called Portfolio. Currently the URL is www.example.com/category/portfolio, how would I display the same page but the url be www.example.com/portfolio?
Maybe I can create a new Template for that page, but how would I display the same results? I was thinking about there might be a URL alias setting?
Creating a template for this is a solution, but I think it will only work efficiently if you have small number of categories.
Try using:
http://wordpress.org/plugins/wp-no-category-base/
http://wordpress.org/plugins/top-level-cats/
I think there are other available plugins to do this.

Display Tumblr blog in Wordpress but only for a certain category

All,
I have a wordpress blog but I have a client that uses Tumblr for their blogs. I know that there are Wordpress plugins out there that import the Tumblr blogs into Wordpress but I don't want to do that. I'd like it to just go out and pull the Tumblr blogs for a category of "News" for example and then display them as Wordpress blog posts.
Has anyone ever done anything like this? Does anyone have an ideas?
Thanks
I actually found PHPTumblr which does everything I need:
https://code.google.com/p/phptumblr/

Categories