<?php
/*cara perbaiki xampp error Error: MySQL shutdown unexpectedly sukses 100%
1. mysqld --console --skip-grant-tables --skip-external-locking
2. mentasi table rusak 
ALTER TABLE yourtable_name DISCARD TABLESPACE ;

ALTER TABLE yourtable_name IMPORT TABLESPACE ;


https://www.youtube.com/watch?v=K7gyclhWo1Y*/
/*error_reporting(0);*/
include('../koneksi.php');
if (isset($_GET['nama']) AND isset($_GET['username'])){
    /*https://www.duniailkom.com/tutorial-form-php-cara-mengirim-variabel-pesan-antar-halaman-php/*/
 
$username = $_POST['username'];
}
$kodeuser   = $_SESSION['username'];
$nama_kantor = $_POST['nama_kantor'];
$nama = $_POST['nama'];
$jabatan = $_POST['jabatan'];
$username = $_POST['username'];

$password = md5($_POST['katasandi']);
$level = $_POST['level'];
$kode = $_POST['kode'];
$gabung = $_SESSION['username'];
$nokode = $_POST['nokode'];

$query = mysqli_query($koneksi,"INSERT INTO user SET id='0',nama='$nama',jabatan='$jabatan',username='$username',pasword='$password',level='$level',kode='$kode',kantor='$nama_kantor',kode_cab='$gabung',pembuat='$kodeuser',nokode='$nokode' ")or die(mysqli_error($koneksi));
echo "Data Sukses Disimpan--!!!";



?>
