Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. <?php
  2. defined('BASEPATH') or exit('No direct script access allowed');
  3.  
  4. class ModelKategori extends CI_Model
  5. {
  6.     public function data_elektronik()
  7.     {
  8.         $result = $this->db->get_where('tb_barang', ['kategori_brg' => 'Electronics']);
  9.         return $result->result_array();
  10.     }
  11.  
  12.     public function data_clothes()
  13.     {
  14.         $result = $this->db->get_where('tb_barang', ['kategori_brg' => 'Clothes']);
  15.         return $result->result_array();
  16.     }
  17.  
  18.     public function data_sports()
  19.     {
  20.         $result = $this->db->get_where('tb_barang', ['kategori_brg' => 'Sports']);
  21.         return $result->result_array();
  22.     }
  23. }