summaryrefslogtreecommitdiff
path: root/static/upload.php
diff options
context:
space:
mode:
authorNeku <neku@pomf.se>2014-10-02 23:09:26 +0200
committerNeku <neku@pomf.se>2014-10-02 23:09:26 +0200
commit7470239a2a4340a06d4e9fc9f57d9ac5c7a7ae43 (patch)
treea5fa285c55f5372839cb74dc88abea291f8d7e3b /static/upload.php
parentd98e61d11d18968a341f8bb54348929406f3afa9 (diff)
not even used, shitty, removed
Diffstat (limited to 'static/upload.php')
-rw-r--r--static/upload.php22
1 files changed, 1 insertions, 21 deletions
diff --git a/static/upload.php b/static/upload.php
index f0adb68..01d5262 100644
--- a/static/upload.php
+++ b/static/upload.php
@@ -30,7 +30,7 @@ function generate_name ($file) {
// If we run out of tries, throw an exception. Should be caught and JSONified.
if ($tries-- == 0) throw new Exception('Gave up trying to find an unused name');
- // TODO: come up with a better name generating algorithm
+ // TODO: come up with a better name generating algorithm, stop repeating myself.
$newname = ''; // Filename Generator:
$newname .= chr(mt_rand(ord("a"), ord("z"))); // + random lowercase letter
$newname .= chr(mt_rand(ord("a"), ord("z"))); // + random lowercase letter
@@ -156,26 +156,6 @@ function upload_file ($file) {
}
}
-
-
-//function expirecalc ($in){
-// switch($in){
-// case '5': $when=5; break;
-// case '15': $when=15; break;
-// case '30': $when=30; break;
-// case '0': $when=NULL; break;
-// default: $when=5;
-// }
-// if ($when == NULL){
-// return NULL;
-//}else{
-// return date('Y-m-d', time() + ($when * 60 * 60 * 24)); }
-//}
-
-
-
-
-
/**
* Reorganize the $_FILES array into something saner
*