When someone trying to or conditions using active record database library in codeigniter. This function is identical to the one above, except that multiple instances are joined by OR.
Note: or_where() was formerly known as orwhere(), which has been removed.
Let’s create a or_where method in codeigniter
$this->db->where('username !=', $username); $this->db->or_where('id >', $id); // Produces: WHERE username != 'alex' OR id > 20