Initial commit: Backup der Webseiten

- zoesch.de
- blitzkiste.net
- gruene-hassberge (norbert.zoesch.de)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Felix Zösch
2025-12-13 01:17:15 +01:00
commit 07c290a453
4607 changed files with 1202735 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
<?php
class Uploader
{
private $filename;
private $fileData;
private $destination;
//declare a constructor method
public function __construct($key)
{
$this->filename = $_FILES[$key]['name'];
$this->fileData = $_FILES[$key]['tmp_name'];
}
public function saveIn($folder)
{
$this->destination = $folder;
}
public function save()
{
$folderIsWriteAble = is_writable($this->destination);
if ($folderIsWriteAble) {
$name = "$this->destination/$this->filename";
$succes = move_uploaded_file($this->fileData, $name);
} else {
trigger_error("cannot write to $this->destination");
$succes = false;
}
return $succes;
}
}