Advertisement
Guest User

Untitled

a guest
Aug 13th, 2017
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. <?php
  2. $host = 'localhost';
  3. $user = 'root';
  4. $pass = 'vertrigo';
  5. $bd = 'dados';
  6.  
  7. $conexao = mysql_connect($host, $user, $pass);
  8. $banco = mysql_select_db($bd,$conexao);
  9. $busca = "SELECT * FROM contato";
  10. $query = mysql_query($busca,$conexao) or die("ERRO ao buscar!");
  11.  
  12.  
  13. while($linha = mysql_fetch_array($query)){
  14. $email = $linha["email"];
  15. $nome = $linha["nome"];
  16. echo $email;
  17. echo $nome;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement