I am trying to query the database with the following script:
<?php
require("conexao.php");
$exibir = mysql_query("SELECT * FROM produtos");
while ($r = mysql_fetch_array($exibir)){
$id = $r['id'];
$nome = $r['nome'];
$altura = $r['altura'];
$peso = $r['peso'];
$imc = $r['imc'];
}
?>
<?php
echo "$nome <br/>";
?>
The code above was to return all table names, but only the last one returns me!
I would like to get back to me all the names !!
What's wrong?