1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
<?php require("configure.php"); $BDayId = $_POST["BDayId"]; $BDayTitleen = htmlspecialchars($_POST["BDayTitleen"],ENT_QUOTES); $BDayDescen = preg_replace("/'/","\'",$_POST["BDayDescen"]); $BDayTitletc = htmlspecialchars($_POST["BDayTitletc"],ENT_QUOTES); $BDayDesctc = preg_replace("/'/","\'",$_POST["BDayDesctc"]); $BDayTitlesc = htmlspecialchars($_POST["BDayTitlesc"],ENT_QUOTES); $BDayDescsc = preg_replace("/'/","\'",$_POST["BDayDescsc"]); //print_r($_POST);
// Modify $sql = "update BDay set BDayTitleen='$BDayTitleen', BDayDescen='$BDayDescen', BDayTitletc='$BDayTitletc', BDayDesctc='$BDayDesctc', BDayTitlesc='$BDayTitlesc', BDayDescsc='$BDayDescsc' "; $sql .= " where BDayId=". $BDayId ." "; mysql_query($sql);
if( mysql_errno() > 0 ){ echo 'Birthday Party Modify Error:<br />'. mysql_error() .'<br />SQL: '. $sql; exit; } mysql_close($dbh);
header("Location: bday_modifyform.php?id=". $BDayId ."&msg=Modify Successful"); ?>
|