CoreFiles by mySites.guru
helper.php33 lines, 857 bytes, from Joomla_2.5.13-Stable-Full_Package.zip
Raw History Compare with 2.5.11
md5
d073c721f7c28f9d11f2d18f6ff35cb7
sha1
647fe712f0743bbaccf83bfe8bcb3cf4b06b70b4
sha256
ce50b6fd003a8a16ea5ea50e6476800dab59c40850b3e8aae86fa75c9bb7d013
<?php
/**
 * @package		Joomla.Site
 * @subpackage	mod_articles_categories
 * @copyright	Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
 * @license		GNU General Public License version 2 or later; see LICENSE.txt
 */

// no direct access
defined('_JEXEC') or die;

require_once JPATH_SITE.'/components/com_content/helpers/route.php';
jimport('joomla.application.categories');

abstract class modArticlesCategoriesHelper
{
	public static function getList(&$params)
	{
		$categories = JCategories::getInstance('Content');
		$category = $categories->get($params->get('parent', 'root'));

		if ($category != null)
		{
			$items = $category->getChildren();
			if($params->get('count', 0) > 0 && count($items) > $params->get('count', 0))
			{
				$items = array_slice($items, 0, $params->get('count', 0));
			}
			return $items;
		}
	}

}

The same content is in 8 releases, Joomla 2.5.9 to 2.5.17. See them all, or every version of this file.