PHP/MySql - DateTime detecting if values was assigned?

vekFrelve

New Member
I want to make an if statement that only runs if the datetime value is NOT null \[code\](0000-00-00 00:00:00)\[/code\]I have passed the value via a query into a variable but how do i determine if it equals \[code\]0000-00-00 00:00:00\[/code\]?\[code\]$query = "SELECT * FROM stats WHERE member_id='" . $_SESSION['SESS_MEMBER_ID'] . "' "; $result = mysql_query($query);while($row = mysql_fetch_array($result, MYSQL_ASSOC)) { $money = $row['money']; $bank_money = $row['bank_money']; $ap = $row['ap']; $exp = $row['exp']; $last_ap_update = $row['last_ap_update'];} if ($last_ap_update != ){ //Can i verify its NULL-ness here so i can run this if stament or run else?}\[/code\]
 
Back
Top