Advertisement
Guest User

Untitled

a guest
Apr 20th, 2014
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. if ($_SESSION["qstn"]!=="")
  2. {
  3. Header("Location:Profile.php");
  4. }
  5. else
  6. {
  7. $con = mysql_connect("localhost","user","pswd");
  8. mysql_select_db("mydb", $con);
  9. //Problem Is the updates made get destroyed on logout ....i want them to be permanent plz help
  10. $sql="UPDATE `data` SET `bin` = '". $_FILES['bin'] ."' , `qstn` = '". $_POST['qstn'] ."' , `ans` = '". $_POST['ans'] ."' WHERE `Username` = '".$_POST['uname']."' ";
  11. mysql_query($sql) or die(mysql_error());
  12. mysql_close($con);
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement