No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
include("conn.php"); $studid=$_POST['studid']; $reg=$_POST['reg']; $sname=$_POST['sname']; $fname=$_POST['fname']; $dob=$_POST['dob']; $course=$_POST['course']; $contact=$_POST['contact']; $address=$_POST['address']; $img=$_POST['img']; //Image Upload $name=time(); $uploaddir = "../img/"; $uploadfile = $uploaddir .$name. basename($_FILES['userfile']['name']); move_uploaded_file($_FILES['userfile']['tmp_name'], $uploadfile); $fpath=$_FILES['userfile']['name']; if($fpath=="") { $fpath=$img; } if($img=="") { $img="default.gif"; } mysql_query("update student set sname='$sname', fname='$fname', dob='$dob', contact='$contact', address='$address', simg='$fpath' where studid=$studid"); |