fix
This commit is contained in:
@@ -11,6 +11,9 @@ class Autopref_model extends CI_Model
|
|||||||
if (isset($_SESSION) && isset($_SESSION['member_id']) && $_SESSION['member_id'] > 0){
|
if (isset($_SESSION) && isset($_SESSION['member_id']) && $_SESSION['member_id'] > 0){
|
||||||
|
|
||||||
$accountAgeNumber = $this->accountAge( $_SESSION['member_id'] );
|
$accountAgeNumber = $this->accountAge( $_SESSION['member_id'] );
|
||||||
|
|
||||||
|
// echo $accountAgeNumber." -----";
|
||||||
|
//exit;
|
||||||
$retArr['returnPage'] ='dash';
|
$retArr['returnPage'] ='dash';
|
||||||
if ($accountAgeNumber < 60 ){
|
if ($accountAgeNumber < 60 ){
|
||||||
$retArr['returnPage'] ='dash/help';
|
$retArr['returnPage'] ='dash/help';
|
||||||
@@ -34,14 +37,14 @@ class Autopref_model extends CI_Model
|
|||||||
$ageQ = "SELECT ((DATE_PART('day', now()::timestamp - added::timestamp) * 24 +
|
$ageQ = "SELECT ((DATE_PART('day', now()::timestamp - added::timestamp) * 24 +
|
||||||
DATE_PART('hour', now()::timestamp - added::timestamp)) * 60 +
|
DATE_PART('hour', now()::timestamp - added::timestamp)) * 60 +
|
||||||
DATE_PART('minute', now()::timestamp - added::timestamp)) * 60 +
|
DATE_PART('minute', now()::timestamp - added::timestamp)) * 60 +
|
||||||
DATE_PART('second', now()::timestamp - added::timestamp) AS accAge FROM members WHERE id =".$member_id;
|
DATE_PART('second', now()::timestamp - added::timestamp) AS accage FROM members WHERE id =".$member_id;
|
||||||
|
|
||||||
$query = $this->db->query($ageQ);
|
$query = $this->db->query($ageQ);
|
||||||
$row = $query->row();
|
$row = $query->row();
|
||||||
|
|
||||||
if (isset($row))
|
if (isset($row))
|
||||||
{
|
{
|
||||||
$accAge = $row->accAge;
|
$accAge = $row->accage;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $accAge;
|
return $accAge;
|
||||||
|
|||||||
Reference in New Issue
Block a user