<?php include("_ayarlar.php"); ?>
<?php include("_fonksiyonlar.php"); ?>
<?php include("_header.php"); ?>

<div class="hero overlay inner-page bg-primary py-5">
    <div class="container">
        <div class="row align-items-center justify-content-center text-center pt-5">
            <div class="col-lg-6">
                <h1 class="heading text-white mb-3" data-aos="fade-up">Bilgilerim</h1>
            </div>
        </div>
    </div>
</div>

<!-- Start retroy layout blog posts -->
<section class="section">
    <div class="container">
        <?php

        if (@$guncelle_mesaj == 1) {
            echo "<div class='alert alert-success'>Güncelleme işlemi başarılı.</div>";
        } else if (@$guncelle_mesaj == 2){
            echo "<div class='alert alert-danger'>Güncelleme işlemi başarısız.</div>";
        }

        ?>
        <form method="post" action="bilgilerim.php">
            <div class="mb-3">
                <label for="ad" class="form-label">Adı</label>
                <input type="text" class="form-control" id="ad" name="ad" value="<?php echo $uye["ad"]; ?>">
            </div>
            <div class="mb-3">
                <label for="soyad" class="form-label">Soyadı</label>
                <input type="text" class="form-control" id="soyad" name="soyad" value="<?php echo $uye["soyad"]; ?>">
            </div>
            <div class="mb-3">
                <label for="eposta" class="form-label">e-Posta</label>
                <input type="email" class="form-control" id="eposta" name="eposta" value="<?php echo $uye["eposta"]; ?>" readonly disabled>
            </div>
            <div class="mb-3">
                <label for="dogum_tarihi" class="form-label">Doğum Tarihi</label>
                <input type="date" class="form-control" id="dogum_tarihi" name="dogum_tarihi" value="<?php echo $uye["dogum_tarihi"]; ?>">
            </div>
            <div class="mb-3">
                <label for="dogum_yeri" class="form-label">Doğum Yeri</label>
                <select class="form-select mb-3" name="dogum_yeri">
                <?php
                    sehir_listele($uye["dogum_yeri"]);
                ?>
                </select>
            </div>
            <button type="submit" class="btn btn-primary" name="guncelle">Güncelle</button>
        </form>
    </div>
</section>
<!-- End retroy layout blog posts -->

<?php include("_footer.php"); ?>