Hello !
How could i edit the code below to upload into a specified temp directory
eg: "/path/to/temp"
And not the servers "/tmp" directory ?
Any help would be greatly appreciated.
<------------------------>
if ($action == "upload")
{
if (isset($binFile) && $binFile != "none")
{
$data = addslashes(fread(fopen("$binFile", "r"), filesize($binFile)));
$strDescription = addslashes(nl2br($txtDescription));
$sql = "INSERT INTO tbl_Files ";
$sql .= "(description, bin_data, filename, filesize, filetype, owner, prop_num) ";
$sql .= "VALUES ('$strDescription', '$data', ";
$sql .= "'$binFile_name', '$binFile_size', '$binFile_type', '$current_user', '$propnum')";
if (!mysql_query ($sql, $link) )
{
die (mysql_error());
}
echo "Your image has been added ($binFile_name).";
}
}
<------------------------>