����JFIF��H�H����Exif��MM�*���� ��3����V�����3������3�(��������������������3�����
Server IP : 162.0.232.25 / Your IP : 18.191.63.237 Web Server : LiteSpeed System : Linux premium276.web-hosting.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64 User : kwacuqig ( 988) PHP Version : 8.2.26 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/kwacuqig/voltify.malawisounds.com/ |
Upload File : |
<?php include './head.php'; include './header.php'; include './navbar.php'; if (isset($_GET['cid'])) { if (!empty($_GET['cid'])) { $cid = $_GET['cid']; $run = mysqli_query($conn, "SELECT * FROM `customers` WHERE `cid`=$cid") or die(mysqli_error($conn)); $row = mysqli_fetch_array($run); } } if (isset($_POST['submit'])) { $fname = mysqli_real_escape_string($conn, htmlentities($_POST['fname'])); $sname = mysqli_real_escape_string($conn, htmlentities($_POST['sname'])); $email = mysqli_real_escape_string($conn, htmlentities($_POST['email'])); $mobile = mysqli_real_escape_string($conn, htmlentities($_POST['mobile'])); $location = mysqli_real_escape_string($conn, htmlentities($_POST['location'])); $meter_number = mysqli_real_escape_string($conn, htmlentities($_POST['meter_number'])); //query $query2 = "UPDATE `customers` SET `firstname`='$fname', `surname`='$sname', `email`='$email', `mobile`='$mobile', `location`='$location', `meter_number`='$meter_number' WHERE `cid`=$cid"; if ($run2 = mysqli_query($conn, $query2)) { ?> <script type="text/javascript"> document.addEventListener("DOMContentLoaded", function(event) { swal("SUCCESS", "<?php echo "$fname $sname"; ?> Was successfully updated", "success"); setTimeout(function() { window.location = 'customer-edit.php?cid=<?php echo $cid;?>'; }, 1500); }); </script> <?php } else { die(mysqli_error($conn)); } } ?> <!-- Form Element area Start--> <div class="form-element-area"> <div class="container-fluid"> <div class="row"> <form action="<?php echo $_SERVER['PHP_SELF'].'?cid='.$cid; ?>" method="POST"> <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12"> <div class="form-element-list mg-t-30"> <div class="row"> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-support"></i> </div> <div class="nk-int-st"> <input type="text" name="fname" class="form-control" placeholder="First Name" value="<?php echo isset($row['firstname']) ? $row['firstname'] : ''; ?>" required> </div> </div> </div> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-support"></i> </div> <div class="nk-int-st"> <input type="text" name="sname" class="form-control" placeholder="Last Name" value="<?php echo isset($row['surname']) ? $row['surname'] : ''; ?>" required> </div> </div> </div> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-mail"></i> </div> <div class="nk-int-st"> <input type="text" name="email" class="form-control" placeholder="Email Address" value="<?php echo isset($row['email']) ? $row['email'] : ''; ?>" required> </div> </div> </div> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-phone"></i> </div> <div class="nk-int-st"> <input type="text" name="mobile" class="form-control" placeholder="Contact Number" value="<?php echo isset($row['mobile']) ? $row['mobile'] : ''; ?>" required> </div> </div> </div> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-house"></i> </div> <div class="nk-int-st"> <input type="text" name="location" class="form-control" placeholder="Location" value="<?php echo isset($row['location']) ? $row['location'] : ''; ?>" required> </div> </div> </div> <div class="col-sm-6 col-xs-12"> <div class="form-group ic-cmp-int float-lb floating-lb"> <div class="form-ic-cmp"> <i class="notika-icon notika-ip-locator"></i> </div> <div class="nk-int-st"> <input type="text" name="meter_number" class="form-control" placeholder="Meter Number" value="<?php echo isset($row['meter_number']) ? $row['meter_number'] : ''; ?>" required> </div> </div> </div> <input type="hidden" name="cid" value="<?php echo $cid;?>"> </div> <center> <div class="form-example-int mg-t-15"> <button type="submit" name="submit" class="btn btn-success notika-btn-success">Update</button> </div> </center> </div> </div> </form> </div> </div> </div> <?php include './footer.php'; include './scripts.php'; ?> <script> document.querySelectorAll(".main-menu-area .nav li")[2].classList.add('active') document.querySelector(".main-menu-area .tab-content #Page").classList.add('in') document.querySelector(".main-menu-area .tab-content #Page").classList.add('active') document.querySelector("title").innerHTML="Voltify ~ Customer Edit"; </script>