Keeps showing up with an error saying index 'image' can't be found, just don't get it, its a field on the form of the previous page!?! Any ideas?
PHP Code:
<?php
//header("Location: ../news/1.htm");
include('../forum/SSI.php');
dbConnect();
global $context;
if($context['user']['is_logged'])
{
$validate_admin = check_admin_userid($context['user']['id']);
$validate = check_sec_admin_userid($context['user']['id'],"3");
if(($validate == true) || ($validate_admin == true))
{
$target_path = "../images/news/";
$target_path = $target_path . basename($_FILES['image']['name']);
if(move_uploaded_file($_FILES['image']['tmp_name'], $target_path))
{
mysql_query("INSERT INTO ".$_GET['table']." VALUES (NULL,'".$_GET['title']."','".$_GET['body']."','".date("Y-m-d")."','".date("G:i:s")."','".basename($_FILES['imagefile']['name'])."',1,'".$_SERVER['REMOTE_ADDR']."')");
}
}
}
closeConnect();
?>