Sebuahhobi98

koneksi.php

May 10th, 2018
282
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.26 KB | None | 0 0
  1. <?php
  2. $db_host = "localhost";
  3. $db_user = "root";
  4. $db_pass = "";
  5. $db_name = "web";
  6.  
  7. $koneksi = mysqli_connect($db_host, $db_user, $db_pass, $db_name);
  8.  
  9. if(mysqli_connect_errno()){
  10.     echo 'Gagal melakukan koneksi ke Database : '.mysqli_connect_error();
  11. }
  12. ?>
Add Comment
Please, Sign In to add comment