Advertisement
Guest User

Koneksi Database

a guest
Jul 21st, 2017
180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. <?php
  2. $host="localhost";
  3. $user="root";
  4. $pass=" ";
  5. $dbase="krida";
  6.  
  7. $con= new mysqli($host,$user,$pass,$dbase);
  8. if($con->connect_erno >0){
  9. trigger_error('Database Gagal Terhubung'.$con->error,E_USER_ERROR);
  10. }else{
  11. echo 'Database Berhasil Terhubung';
  12. }
  13. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement