Welcome Guest, Not a member yet? Register   Sign In
Validation Callback function not working
#8

[eluser]terry101[/eluser]
jblack199 i tried what you suggested but no dice. Mirge the 1 was always included and no dice either. Any other suggestions on what could be possibly wrong?


Code:
function dbcheck ($username) {
    
            $checkusername = array('username' => $username);
            $verifyusername = $this->db->get_where('tbregister', $checkusername);
var_dump($verifyusername);
//$this->db->where('username', $username);
//$verifyusername = $this->db->get('tbregister');
            if ($verifyusername->num_rows() == 1) {
                
            $this->form_validation->set_message('dbcheck','%s already exists!');
                return FALSE;
            }
            else {
                
                return TRUE;
            }
        }

i tried var_dump($verifyusername); and i get nothin below, so nothing getting passes?

object(CI_DB_mysql_result)[17]
public 'conn_id' => resource(29, mysql link persistent)
public 'result_id' => resource(34, mysql result)
public 'result_array' =>
array
empty
public 'result_object' =>
array
empty
public 'custom_result_object' =>
array
empty
public 'current_row' => int 0
public 'num_rows' => int 16
public 'row_data' => null


Messages In This Thread
Validation Callback function not working - by El Forum - 08-12-2011, 06:50 PM
Validation Callback function not working - by El Forum - 08-12-2011, 07:20 PM
Validation Callback function not working - by El Forum - 08-12-2011, 08:39 PM
Validation Callback function not working - by El Forum - 08-12-2011, 08:43 PM
Validation Callback function not working - by El Forum - 08-12-2011, 09:09 PM
Validation Callback function not working - by El Forum - 08-12-2011, 09:20 PM
Validation Callback function not working - by El Forum - 08-12-2011, 09:40 PM
Validation Callback function not working - by El Forum - 08-12-2011, 09:52 PM
Validation Callback function not working - by El Forum - 08-12-2011, 10:51 PM
Validation Callback function not working - by El Forum - 08-13-2011, 09:55 AM
Validation Callback function not working - by El Forum - 08-13-2011, 10:07 AM
Validation Callback function not working - by El Forum - 08-13-2011, 11:39 AM
Validation Callback function not working - by El Forum - 08-13-2011, 12:14 PM
Validation Callback function not working - by El Forum - 08-13-2011, 01:55 PM
Validation Callback function not working - by El Forum - 08-13-2011, 03:14 PM
Validation Callback function not working - by El Forum - 08-13-2011, 04:54 PM



Theme © iAndrew 2016 - Forum software by © MyBB