php - MYSQL Query not able to pull data from Database -


The problem I have is that my query:

  SELECT * to the Administrator Administrator WHERE nombre_administrador =? And password =?   

Nothing is pulling from the database.

var_dump Shows:

  public 'Infect_rows' = & gt; Blank, public 'insert_id' = & gt; Nulled public 'num_rows' = & gt; Blank Public 'param_count' = & gt; Null public 'field_count' = & gt; Weak public 'error' = & gt; Weak public 'error' = & gt; Null public 'error_list' = & gt; Zero public 'sqlstate' = & gt; Weak public 'id' = & gt; Null   

login.php

  & lt ;? Php class login {// MySQL connection to personal variable $; Private $ sql; Private $ table mister; // Field variable private $ pass; Private $ name; Public function __construct () {// Get the name of the table and make connections $ this-> Mysqli = UniversalConnect :: doConnect (); // Get data from HTML form- it-> Name = $ _ POST ['name']; $ This- & gt; Passed = $ _ post ['pass']; // Call my personal methods for MySQL operations $ this-> Dologin (); $ This- & gt; Mysqli- & gt; near (); } Personal Function Dologin (if ($ stmt = $ this-> mysqli- & gt; Ready ("SELECT * FROM administradores WHERE nombre_administrador =? And password =?")) {Var_dump ($ stmt); / * Bound parameters for markers * / $ stmt- & gt; Dam_param ('ss', $ this- & gt; name, $ this- & gt; pass); var_dump ($ this- & gt; name); var_dump ($ This-> pass); / * execute query * / $ stmt- & gt; execute (); / * bind result variables * / $ stmt- & gt; bind_celt ($ id, $ nombre_administrador, $ password, $ Ubicacion, $ nombre, $ apellido); / * fetch value * / $ stmt- & gt; fetch (); / * get the number of rows * / $ num_row = $ stmt- & Gt; num_rows; if ($ num_row == 1) {echo 'true'; $ _SESSION ['name'] = $ line ['nombre_administrador']; $ _SESSION ['id'] = $ line ['id'] ; Header ("Location: http: //localhost/SCAF1.0/indexSCAF.html");} Else {echo "



  

Comments

Popular posts from this blog

java - ImportError: No module named py4j.java_gateway -

python - Receiving "KeyError" after decoding json result from url -

java - Session timeout does't work vaadin -