Skip to content

Instantly share code, notes, and snippets.

@romeo1
Created March 3, 2014 19:07
Show Gist options
  • Save romeo1/9332310 to your computer and use it in GitHub Desktop.
Save romeo1/9332310 to your computer and use it in GitHub Desktop.
Untuk Koneksi nya buat folder koneksi dan simpan dengan nama koneksi.php
<?php
$mysql_user="root";
$mysql_password="root";
$mysql_database="dbuniversitas";
$mysql_host="localhost";
//---[KONEKSI KE DATABASE]---//
$koneksi=mysql_connect($mysql_host,$mysql_user,$mysql_password);
if (!$koneksi){
die('koneksi gagal :' .mysql_error());
}
//===[ PILIH DATABASE YANG AKAN DIGUNAKAN ]=====//
mysql_select_db($mysql_database);
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment