first commit
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
class Faq_model extends CI_Model {
|
||||
|
||||
var $optCons = '';
|
||||
var $currentStyle = 'form-control select';
|
||||
|
||||
function __construct() {
|
||||
|
||||
}
|
||||
|
||||
public function attachOffers($email) {
|
||||
$emailTrim = trim($email);
|
||||
$mysql = "SELECT id AS member_id FROM members WHERE username = '$emailTrim' LIMIT 1 ";
|
||||
$query = $this->db->query($mysql);
|
||||
|
||||
$num = $query->num_rows();
|
||||
if ($num == 1) {
|
||||
|
||||
// $out = $query->result_array();
|
||||
// print_r($out);
|
||||
$mysqlU = " UPDATE members_jobs_offer SET client_id ='". $query->row()->member_id ."' WHERE client_id = 0 AND email='$emailTrim' AND expire> now()";
|
||||
$this->db->query($mysqlU);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user