Ver Mensaje Individual
  #7 (permalink)  
Antiguo 08/11/2014, 21:42
sam03
 
Fecha de Ingreso: febrero-2014
Mensajes: 69
Antigüedad: 11 años
Puntos: 0
Respuesta: problemas con num_rows

Gracias!!!! me ayudaste mucho, al final el código quedo así:

Código PHP:
    public function validar()
    {
        
$sql "SELECT CONTRASENA FROM tbl_empleados WHERE CARNET = '".$this->CARNET."'";

        
$result $this->consulta($sql);

        if(
is_array($result))
        {
            
$d $result[0];

            if( 
strcmp($this->CONTRASENA,$d["CONTRASENA"]) == )
            {
                return 
true;  
            }
                                      
            else
            {
                return 
false;
            }                   
                
        }
        else
        {
            return 
false;
        }
    }