Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include("connection.php");
- $firstname=$_POST['firstname'];
- $lastname=$_POST['lastname'];
- $username=$_POST['username'];
- $password=$_POST['password'];
- $address=$_POST['address'];
- $town=$_POST['town'];
- $country=$_POST['country'];
- $postcode=$_POST['postcode'];
- $email=$_POST['email'];
- $sql="update user set firstname='$firstname', lastname='$lastname', password='$password',
- address='$address', town='$town' , country='$country' , postcode='$postcode' , email='$email'
- where username='$username'";
- if(mysql_query($sql)){
- echo '<script type="text/javascript">
- //<![CDATA[
- alert ("Berhasil Edit");
- window.location="showuser.php";
- //]]>
- </script>';
- } else {
- echo '<script type="text/javascript">
- //<![CDATA[
- alert ("Gagal Simpan");
- window.location="showuser.php";
- //]]>
- </script>';
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement