hjkhghopjkertteerterterterertertrtoirh
bnmbertsurhetertertertertertertertpdf'tdfg
/
home
/
easy3158
/
domains
/
ekwiatki.pl
/
public_html
/
Upload FileeE
HOME
<?php include("inc/head.php"); if(empty($_SESSION['user_id'])){header("Location: login");exit;} ?> <body> <!-- header start --> <?php include("inc/top.php"); ?> <!--====================================================--> <div class="breadcrumb-area gray-bg"> <div class="container"> <div class="breadcrumb-content"> <ul> <li><a href="index">ekwiatki.pl</a></li> <li class="active">Moje dane</li> </ul> </div> </div> </div> <!-- my account start --> <?php $q = mysqli_query($connect,"SELECT * FROM `users` WHERE `id` = ".$_SESSION['user_id']); $s = mysqli_fetch_array($q); $imie = $s['imie']; $nazwisko = $s['nazwisko']; $telefon = $s['telefon']; $ulica = $s['ulica']; $nr_domu = $s['nr_domu']; $nr_lokalu = $s['nr_lokalu']; $zip = $s['zip']; $miasto = $s['miasto']; $firma_nazwa = $s['firma_nazwa']; $firma_nip = $s['firma_nip']; $firma_ulica = $s['firma_ulica']; $firma_nr_domu = $s['firma_nr_domu']; $firma_nr_lokalu = $s['firma_nr_lokalu']; $firma_zip = $s['firma_zip']; $firma_miasto = $s['firma_miasto']; //============================================================== $try1POST = trim(addslashes(strip_tags($_POST['try1']))); $imiePOST = trim(addslashes(strip_tags($_POST['imie']))); $nazwiskoPOST = trim(addslashes(strip_tags($_POST['nazwisko']))); $ulicaPOST = trim(addslashes(strip_tags($_POST['ulica']))); $nr_domuPOST = trim(addslashes(strip_tags($_POST['nr_domu']))); $nr_lokaluPOST = trim(addslashes(strip_tags($_POST['nr_lokalu']))); $zipPOST = trim(addslashes(strip_tags($_POST['zip']))); $miastoPOST = trim(addslashes(strip_tags($_POST['miasto']))); if(!empty($try1POST) AND $try1POST == "1"){ mysqli_query($connect,"UPDATE `users` SET `imie` = '$imiePOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `nazwisko` = '$nazwiskoPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `ulica` = '$ulicaPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `nr_domu` = '$nr_domuPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `nr_lokalu` = '$nr_lokaluPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `zip` = '$zipPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `miasto` = '$miastoPOST' WHERE `id` = ".$_SESSION['user_id']); header("Location: profileSaved"); } //============================================================== $try2POST = trim(addslashes(strip_tags($_POST['try2']))); $firma_nazwaPOST = trim(addslashes(strip_tags($_POST['firma_nazwa']))); $firma_nipPOST = trim(addslashes(strip_tags($_POST['firma_nip']))); $firma_ulicaPOST = trim(addslashes(strip_tags($_POST['firma_ulica']))); $firma_nr_domuPOST = trim(addslashes(strip_tags($_POST['firma_nr_domu']))); $firma_nr_lokaluPOST = trim(addslashes(strip_tags($_POST['firma_nr_lokalu']))); $firma_zipPOST = trim(addslashes(strip_tags($_POST['firma_zip']))); $firma_miastoPOST = trim(addslashes(strip_tags($_POST['firma_miasto']))); if(!empty($try2POST) AND $try2POST == "1"){ mysqli_query($connect,"UPDATE `users` SET `firma_nazwa` = '$firma_nazwaPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_nip` = '$firma_nipPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_ulica` = '$firma_ulicaPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_nr_domu` = '$firma_nr_domuPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_nr_lokalu` = '$firma_nr_lokaluPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_zip` = '$firma_zipPOST' WHERE `id` = ".$_SESSION['user_id']); mysqli_query($connect,"UPDATE `users` SET `firma_miasto` = '$firma_miastoPOST' WHERE `id` = ".$_SESSION['user_id']); header("Location: profileSaved"); } //============================================================== $try3POST = trim(addslashes(strip_tags($_POST['try3']))); $pass1 = trim(addslashes(strip_tags($_POST['pass1']))); $pass2 = trim(addslashes(strip_tags($_POST['pass2']))); if(!empty($try3POST) AND $try3POST == "1"){ if($pass1 == $pass2){ $pass = sha1(md5($pass1)); mysqli_query($connect,"UPDATE `users` SET `password` = '$pass' WHERE `id` = ".$_SESSION['user_id']); header("Location: profileSaved"); } else {header("Location: profilePassError");} } ?> <div class="checkout-area pb-55 pt-75"> <div class="container"> <div class="row"> <div class="ml-auto mr-auto col-lg-9"> <div class="checkout-wrapper"> <?php if(!empty($_GET['saved']) AND $_GET['saved'] == "1"){ if($_GET['passerror'] == "1"){ echo ' <CENTER> <img src="assets/images/warning.png" style="max-width: 140px;"> <h4 style="margin-top: 10px; margin-bottom: 16px;">Podane hasła muszą być identyczne!</h4> <a class="btn btn-danger" style="border-radius: 4px;" href="profile">Powrót</a> </CENTER> '; } else { echo ' <CENTER> <img src="assets/images/done.gif" style="max-width: 180px;"> <h4 style="margin-bottom: 16px;">Zmiany zostały zapisane!</h4> <a class="btn btn-danger" style="border-radius: 4px;" href="profile">Powrót</a> </CENTER> '; } } else { ?> <div id="faq" class="panel-group"> <div class="panel panel-default"> <div class="panel-heading"> <h5 class="panel-title"><span>1</span> <a data-toggle="collapse" data-parent="#faq" href="#my-account-1">Moje dane personalne</a></h5> </div> <div id="my-account-1" class="panel-collapse collapse show"> <div class="panel-body"> <div class="billing-information-wrapper"> <form action="" method="post"> <div class="row"> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Imię</label> <input type="text" name="imie" value="<?=$imie;?>" required> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Nazwisko</label> <input type="text" name="nazwisko" value="<?=$nazwisko;?>" required> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Adres e-mail</label> <input type="text" value="<?=$emailUserData;?>" style="background: #efefef;" disabled> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Telefon</label> <input type="text" value="<?=$telefon;?>" style="background: #efefef;" disabled> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Ulica</label> <input type="text" name="ulica" value="<?=$ulica;?>"> </div> </div> <div class="col-lg-3 col-md-3"> <div class="billing-info"> <label>Nr domu</label> <input type="text" name="nr_domu" value="<?=$nr_domu;?>"> </div> </div> <div class="col-lg-3 col-md-3"> <div class="billing-info"> <label>Nr lokalu</label> <input type="text" name="nr_lokalu" value="<?=$nr_lokalu;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Kod pocztowy</label> <input type="text" name="zip" value="<?=$zip;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Miasto</label> <input type="text" name="miasto" value="<?=$miasto;?>"> </div> </div> </div> <div class="billing-back-btn"> <div class="billing-back"> </div> <div class="billing-btn"> <input type="hidden" name="try1" value="1"> <button type="submit">Zapisz</button> </div> </div> </form> </div> </div> </div> </div> <div class="panel panel-default"> <div class="panel-heading"> <h5 class="panel-title"><span>2</span> <a data-toggle="collapse" data-parent="#faq" href="#my-account-3">Dane mojej firmy</a></h5> </div> <div id="my-account-3" class="panel-collapse collapse"> <div class="panel-body"> <div class="billing-information-wrapper"> <form action="" method="post"> <div class="row"> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Nazwa firmy</label> <input type="text" name="firma_nazwa" value="<?=$firma_nazwa;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>NIP</label> <input type="text" name="firma_nip" value="<?=$firma_nip;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Ulica</label> <input type="text" name="firma_ulica" value="<?=$firma_ulica;?>"> </div> </div> <div class="col-lg-3 col-md-3"> <div class="billing-info"> <label>Nr domu</label> <input type="text" name="firma_nr_domu" value="<?=$firma_nr_domu;?>"> </div> </div> <div class="col-lg-3 col-md-3"> <div class="billing-info"> <label>Nr lokalu</label> <input type="text" name="firma_nr_lokalu" value="<?=$firma_nr_lokalu;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Kod pocztowy</label> <input type="text" name="firma_zip" value="<?=$firma_zip;?>"> </div> </div> <div class="col-lg-6 col-md-6"> <div class="billing-info"> <label>Miasto</label> <input type="text" name="firma_miasto" value="<?=$firma_miasto;?>"> </div> </div> </div> <div class="billing-back-btn"> <div class="billing-back"> </div> <div class="billing-btn"> <input type="hidden" name="try2" value="1"> <button type="submit">Zapisz</button> </div> </div> </form> </div> </div> </div> </div> <div class="panel panel-default"> <div class="panel-heading"> <h5 class="panel-title"><span>3</span> <a data-toggle="collapse" data-parent="#faq" href="#my-account-2">Zmień hasło</a></h5> </div> <div id="my-account-2" class="panel-collapse collapse"> <div class="panel-body"> <div class="billing-information-wrapper"> <form action="" method="post"> <div class="row"> <div class="col-lg-12 col-md-12"> <div class="billing-info"> <label>Nowe hasło</label> <input type="password" name="pass1" required> </div> </div> <div class="col-lg-12 col-md-12"> <div class="billing-info"> <label>Powtórz nowe hasło</label> <input type="password" name="pass2" required> </div> </div> </div> <div class="billing-back-btn"> <div class="billing-back"> </div> <div class="billing-btn"> <input type="hidden" name="try3" value="1"> <button type="submit">Zmień hasło</button> </div> </div> </form> </div> </div> </div> </div> </div> <?php } ?> </div> </div> </div> </div> </div> <!--====================================================--> <?php include("inc/footer.php"); ?> <!-- all js here --> <?php include("inc/footerScripts.php"); ?> </body> </html>