Mini Shell

Direktori : /home/athamevents/public_html/admin/
Upload File :
Current File : /home/athamevents/public_html/admin/work_update.php

<?php include 'connection.php'; ?>
<?php

$postby=$_REQUEST['postby'];

$id=$_REQUEST['id'];

$name=$_REQUEST['name'];

$details=$_REQUEST['details'];


$date=date("Y/m/d");

$image=$_FILES["x"]["name"];

if($image)
{
$temp=$_FILES["x"]["tmp_name"];
move_uploaded_file("$temp","work_pic/$image");

   
$reg=mysql_query(" UPDATE work SET work='$name',details='$details',pic='$image',admin='$postby'  WHERE id='$id'");
}
else
{
$reg=mysql_query("UPDATE work SET work='$name',details='$details',admin='$postby' WHERE id='$id'");
}



if($reg==1)
{
?>



<script type="text/javascript">
var cn=<?php  echo $id ?>;
 window.location.href="work_view.php?pp1="+ cn;

</script>
<?php

}
else
{
?>
<script type="text/javascript">

alert("Not complete");
var cn=<?php  echo $id ?>;
 window.location.href="work_view.php?id="+ cn;

</script>
<?php
}
?>

Zerion Mini Shell 1.0