awoken adlı üyeden alıntı: mesajı görüntüle
function insertPayment($uid, $amount,$rand) {        
$this->db->insert('payments', array(          
 'amount' => (float)$amount,          
 'user' => $uid,            
 'hash' =>$rand,          
 'time' => time(),            
 'status' => 0      
 ));        
return $this->db->insert_id();
}
Kısmını şununla değiştirin:
function insertPayment($uid, $amount,$rand) {        
$this->db->insert('payments', array(          
 'amount' => (float)$amount,          
 'user' => $uid,            
 'hash' =>$rand,          
 'time' => time(),            
 'status' => 0      
 ));        
return [
'id' => $this->db->insert_id(),
'hash' => $rand
];
}
Ardından şöyle çekebilirsiniz:
$data = $this->Payment_Model->insertPayment($this->user['id'], $this->input->post('amount'));
$order_id = $data['id'];
$hash = $data['hash'];
çok teşekkürler hocam bu arada kodlar tanıdık geldimi size bi yerden .