\!/ KyuuKazami \!/

Path : /home/kohli/public_html/application/models/
Upload :
Current File : /home/kohli/public_html/application/models/contentm.php

<?php
class Contentm extends CI_Model  {
    
    function __construct(){
        parent::__construct();        
    }
    
	function get_description($title){
        $this->db->where("title",$title);        
		$q = $this->db->get('matter');
        $result = $q->row_array();
		/*
        $result = array();
		foreach($q->result() as $value)
			$result[] = $value;
        */
		return $result['matter'];
	}
    
    function get_all_contents($limit){
        $this->db->order_by("title");
        $this->db->limit($limit);
		$q = $this->db->get('matter');        
        $result = $q->result();		
		return $result;
    }
    function get_content($id,$name){
        $this->db->where("matter_id",$id);
        $this->db->order_by("title");
		$q = $this->db->get('matter');        
        $result = $q->result();	
      //  echo $this->db->last_query();	
		return $result;
    }
}

@KyuuKazami