mysql - How to use curtime() to check in column with now() structure? SQL -


in db when new user register use now() column date_added (i need exact time of registration). store user ip in column ip

now need check in sql if there registration ip today

but

    $query = $this->db->query("select * " . db_prefix . "customer      ip = '" . $this->db->escape($ip) . "'      , date_added = curdate()");      return $query->row; 

does not work because use now() date_added , now() not = curdate()

any ideas how trick?

use date()

... , date(date_added) = curdate() 

Comments

Popular posts from this blog

javascript - Unusual behaviour when drawing lots of images onto a large canvas -

how can i manage url using .htaccess in php? -

ios - I get the error Property '...' not found on object of type '...' -