5 #include "menulist.html"
6 #include "static-configuration"
9 // We just email notification for now. Auto-analysis RSN.
10 if ($_FILES["uploadedfile"]["error"] > 0) {
11 echo "Error: " . $_FILES["uploadedfile"]["error"] . "<br />";
15 $dest = tempnam($tempfolder, "upload-");
16 move_uploaded_file($_FILES["uploadedfile"]["tmp_name"], $dest);
18 $subject = "CCAN: code upload by '" . $_POST['email'] . "' with name " . $_FILES["uploadedfile"]["name"];
19 $message = "File type: ".$_FILES["uploadedfile"]["type"]."\n".
20 "Size: ".$_FILES["uploadedfile"]["size"]."\n".
21 "Claimed email: ".$_POST['email']."\n".
22 "File destination: ".$dest."\n";
24 mail($ccanadmin, $subject, $message, "From: $frommail");
25 echo "<div align=\"center\"> Thanks!<br>
26 Mail will be send to admin to publish the code.<//div>";