mirror of
https://github.com/Qbix/webserver.git
synced 2026-07-22 07:57:23 +02:00
Added tests
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
Q::header('Content-Type: application/json');
|
||||
$result = ['post' => $_POST, 'files' => []];
|
||||
foreach ($_FILES as $k => $f) {
|
||||
$result['files'][$k] = [
|
||||
'name' => $f['name'], 'size' => $f['size'],
|
||||
'type' => $f['type'], 'error' => $f['error'],
|
||||
'content' => file_get_contents($f['tmp_name']),
|
||||
];
|
||||
}
|
||||
echo json_encode($result);
|
||||
Reference in New Issue
Block a user