forked from karry26/Activity_logger
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprofile-process.php
More file actions
51 lines (27 loc) · 949 Bytes
/
profile-process.php
File metadata and controls
51 lines (27 loc) · 949 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
include_once("connect.php");
$uid=$_POST["uid"];
$mobile=$_POST["mobile"];
$btn=$_POST["btn"];
$des=$_POST["designation"];
$name= $_POST["name"];
// $dob= $_POST["dob"];
$email=$_POST["email"];
//=====================Upload Image==========
$picname=$_FILES["pic"]["name"];
$hdn=$_POST["hdn"];
//$size=$_FILES["ppic"]["size"];
$temp_name=$_FILES["pic"]["tmp_name"];
if($picname=="")
$picname=$hdn;
else
move_uploaded_file($temp_name,"uploads/".$picname);
//echo "<h2>File Uploaded..</h2>";
$query="update users set name='$name',email='$email',mobile='$mobile',designation='$des' , pic='$picname' where uid='$uid'";
mysqli_query($dbRef,$query);
$msg=mysqli_error($dbRef);
if($msg=="")
header("Location: ./dashboard.php");
else
echo $msg;
?>