<?php
    require_once("koneksi.php");
    include 'header.php';
?>

    <!-- breadcrumbs -->
        <div class="breadcrumbs">
            <div class="container">
                <ol class="breadcrumb breadcrumb1">
                    <li><span><i class="fa fa-sign-in" aria-hidden="true"></i><a href="login.php"> Masuk</a></span></li>
                    <li class="active">Form Kelola Buku</li>
                </ol>
            </div>
        </div>
    <!-- //breadcrumbs -->
    <!-- register -->
        <div class="register">
            <div class="container">
                <h2>Form Ubah Informasi Data Diri</h2>
                <div class="login-form-grids">
                    <h5>Informasi Data Diri</h5>
                    <?php
                    $id_nama   = mysqli_real_escape_string($_GET['id']);
                    $cari      = mysqli_query($koneksi, "SELECT * FROM t_user WHERE id_user='$id_nama'")or die(mysqli_error());
                    while($data = mysqli_fetch_array($cari)) {
                    ?>      
                    <form  action="editprofile_process.php" method="POST">
                        <input type="hidden" name="id" placeholder="ID User" value="<?php echo $data['id_user'] ?>" >
                        Nama Lengkap    :
                        <input type="text" name="nama_lengkap" placeholder="Nama Lengkap" value="<?php echo $data['nama_lengkap'] ?>" >
                        Alamat          :
                        <input type="text" name="alamat" placeholder="Alamat" value="<?php echo $data['alamat'] ?>" ><br>
                        Nomor Ponsel    :
                        <input type="text" name="nomor_ponsel" placeholder="Nomor Ponsel" value="<?php echo $data['nomor_ponsel'] ?>" >
                        Email           :
                        <input type="email" name="email" placeholder="Email" value="<?php echo $data['email'] ?>" >
                        <div class="register-check-box">
                            <div class="check">
                                <label class="checkbox"><input type="checkbox" name="checkbox" required=" " ><i> </i>Saya telah mengetahui dan setuju</label>
                            </div>
                        </div>
                        <input type="submit" name="simpan" value="simpan">
                    </form>
                    <?php   
                        }
                    ?>
                </div>
                <div class="register-home">
                    <a href="editprofile.php">Batal</a>
                </div>
            </div>
        </div>
    <!-- //register -->
    
<?php
    include 'footer.php';
?>