[ Mini Kiebo ]
Server: Windows NT AKFAR_SERVER 10.0 build 26200 (Windows 10) AMD64
Path:
D:
/
xampp
/
htdocs
/
simkeu
/
dummy-old
/
application
/
models-old
/
[
Home
]
File: login_model.php
<?php class Login_model extends CI_Model { var $table = 'ueu_tbl_user'; function __construct() { parent::__construct(); } function check_user($username, $password) { $query = $this->db->get_where($this->table, array('username' => $username, 'password' => $password), 1, 0); if ($query->num_rows() > 0) { return TRUE; } else { return FALSE; } } function get_id_pass($username,$password){ $this->db->select('*'); $this->db->from('ueu_tbl_user'); $this->db->where('username',$username); $this->db->where('password',$password); return $this->db->get(); } function kosong_data(){ $this->db->where('id_unit !=', 0); $this->db->delete('ueu_tbl_user'); } function update_login($idlog, $a) { $this->db->where('idlog', $idlog); $this->db->update('ueu_tbl_user', $a); } public function cek_login_by_idlog($idlog) { $this->db->where('idlog', $idlog); return $this->db->get('ueu_tbl_user'); } }