Welcome Guest, Not a member yet? Register   Sign In
Get something or something and other from mysql
#2

[eluser]Ben Edmunds[/eluser]
Maybe this is what you're looking for?

Code:
$query = $this->db->select('user')
                  ->where(array('name'=>$_POST['name']))
                  ->or_where(array('mail'=>$_POST['mail']))
                  ->get('users_table');

$user = $query->row();

Note that the chaining only works on php5...


Messages In This Thread
Get something or something and other from mysql - by El Forum - 11-08-2009, 03:10 PM
Get something or something and other from mysql - by El Forum - 11-08-2009, 05:48 PM
Get something or something and other from mysql - by El Forum - 11-08-2009, 06:07 PM



Theme © iAndrew 2016 - Forum software by © MyBB