Model/Base.php
public function listByCategory($cat = null)
    {
        $result = $this->db->query('SELECT id, title, resume, category, author, link  
                                      FROM '.$this->articleTable.' 
                                      WHERE category = :cat', [':cat'=>$cat]);
        if (isset($result[0])) {
            return $this->comList($result);
        }
        return false;
    }
public function listByCategory($cat = null)
    {
        $result = $this->db->query('SELECT id, title, resume, category, author, link  
                                      FROM '.$this->articleTable.' 
                                      WHERE category = :cat', [':cat'=>$cat]);
        if (isset($result[0])) {
            return $this->comList($result);
        }
        return false;
    }
public function listByCategory ( $ cat = null ) { $ result = $ this -> db -> query ( 'SELECT id, title, resume, category, author, link  
                                      FROM ' . $ this -> articleTable . ' 
                                      WHERE category = :cat' , [ ':cat' => $ cat ] ) ; if ( isset ( $ result [ 0 ] ) ) { return $ this -> comList ( $ result ) ; } return false ; }
List ao article in this category

@param  integer $cat category id

@return array|bool data result or false
List ao article in this category