aboutsummaryrefslogtreecommitdiffstats
path: root/php/upload.php
diff options
context:
space:
mode:
Diffstat (limited to 'php/upload.php')
-rw-r--r--php/upload.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/php/upload.php b/php/upload.php
index 55ff4a4..b36a0f1 100644
--- a/php/upload.php
+++ b/php/upload.php
@@ -2,6 +2,7 @@
require_once "database.php";
require_once "configuration.php";
+session_start();
echo 1;
if (!isset( $_POST["filename"]) || !isset($_FILES["the_file"]))
{
@@ -13,10 +14,11 @@ echo 2;
$file=$_FILES["the_file"];
$filename=$_POST["filename"];
+$homedir=$_SESSION['user_object'];
echo 3;
-$codename=$database->create_file_node($filename);
+$codename=$database->create_file_node($filename,"",$_SESSION['user_object']->home_directory);
echo $codename;
if($codename=="error")
{