SHARE
TWEET

Untitled

a guest Apr 21st, 2017 47 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. $mysqli = new mysqli("localhost", "root", "admin", "base");
  3.  
  4. /* Comprueba la conexión */
  5. if ($mysqli->connect_errno) {
  6.     printf("Connect failed: %sn", $mysqli->connect_error);
  7.     exit();
  8. }
  9.  
  10. if (!$mysqli->query("SET a=1")) {
  11.     printf("Errormessage: %sn", $mysqli->error);
  12. }
  13.  
  14. /* Cierra la conexión */
  15. $mysqli->close();
  16. ?>
RAW Paste Data
Top