Beispiel #1
0
	public function getCategory( )
	{
		$category	=	new cbblogsCategoryTable( $this->_db );

		if ( ! $category->load( (int) $this->get( 'catid' ) ) ) {
			return false;
		}

		return $category;
	}
Beispiel #2
0
	public function getCategory( )
	{
		static $cache	=	array();

		$id				=	(int) $this->get( 'catid' );

		if ( ! isset( $cache[$id] ) ) {
			$category	=	new cbblogsCategoryTable( $this->_db );

			$category->load( $id );

			$cache[$id]	=	$category;
		}

		return $cache[$id];
	}