Просмотр файла news/app/Models/Pages_Model.php
<?php class Pages_Model extends Controller { public function all_news_count() { return count($this->db->exec("SELECT * FROM `".$this->prefix."-news`")); } public function all_news_sql($limit) { return $this->db->exec("SELECT * FROM `".$this->prefix."-news` ORDER BY news_id DESC $limit"); } }