SimplePie::get_category PHP Method

get_category() public method

Get a category for the feed
public get_category ( integer $key ) : SimplePie_Category | null
$key integer The category that you want to return. Remember that arrays begin with 0, not 1
return SimplePie_Category | null
    public function get_category($key = 0)
    {
        $categories = $this->get_categories();
        if (isset($categories[$key])) {
            return $categories[$key];
        } else {
            return null;
        }
    }