alert('Invalid format. Only jpg / jpeg/ png /gif format allowed');"; } else { //rename the image file $imgnewfile = md5($imgfile) . $extension; // Code for move image into directory move_uploaded_file($_FILES["profile_photo"]["tmp_name"], "../admin/img/profile-photos/" . $imgfile); if (isset($_SESSION['member_profile_id']) && $_SESSION['member_profile_id'] != '') { $sql1 = "UPDATE member_profile SET profile_photo='$imgfile' WHERE member_profile_id='" . $_SESSION['member_profile_id'] . "'"; if (mysqli_query($con, $sql1)) { //echo "Records inserted successfully."; { echo ""; } } else { $ermsg = "Either Email ID or Password is Incorrect..!"; } //if ($query) { //$msg = " Your Personal Information updated "; // } else { //$error = "Something went wrong . Please try again."; // } } } } ?>

Add New Your Profile Picture :-