1--TEST--
2rfc1867 MAX_FILE_SIZE
3--INI--
4file_uploads=1
5upload_max_filesize=1024
6max_file_uploads=10
7--POST_RAW--
8Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737
9-----------------------------20896060251896012921717172737
10Content-Disposition: form-data; name="MAX_FILE_SIZE"
11
121
13-----------------------------20896060251896012921717172737
14Content-Disposition: form-data; name="file1"; filename="file1.txt"
15Content-Type: text/plain-file1
16
171
18-----------------------------20896060251896012921717172737
19Content-Disposition: form-data; name="file2"; filename="file2.txt"
20Content-Type: text/plain-file2
21
2222
23-----------------------------20896060251896012921717172737
24Content-Disposition: form-data; name="file3"; filename="C:\foo\bar/file3.txt"
25Content-Type: text/plain-file3;
26
273
28-----------------------------20896060251896012921717172737--
29--FILE--
30<?php
31var_dump($_FILES);
32var_dump($_POST);
33if (is_uploaded_file($_FILES["file1"]["tmp_name"])) {
34	var_dump(file_get_contents($_FILES["file1"]["tmp_name"]));
35}
36if (is_uploaded_file($_FILES["file3"]["tmp_name"])) {
37	var_dump(file_get_contents($_FILES["file3"]["tmp_name"]));
38}
39?>
40--EXPECTF--
41array(3) {
42  ["file1"]=>
43  array(5) {
44    ["name"]=>
45    %string|unicode%(9) "file1.txt"
46    ["type"]=>
47    %string|unicode%(16) "text/plain-file1"
48    ["tmp_name"]=>
49    %string|unicode%(%d) "%s"
50    ["error"]=>
51    int(0)
52    ["size"]=>
53    int(1)
54  }
55  ["file2"]=>
56  array(5) {
57    ["name"]=>
58    %string|unicode%(9) "file2.txt"
59    ["type"]=>
60    %string|unicode%(0) ""
61    ["tmp_name"]=>
62    %string|unicode%(0) ""
63    ["error"]=>
64    int(2)
65    ["size"]=>
66    int(0)
67  }
68  ["file3"]=>
69  array(5) {
70    ["name"]=>
71    %string|unicode%(9) "file3.txt"
72    ["type"]=>
73    %string|unicode%(16) "text/plain-file3"
74    ["tmp_name"]=>
75    %string|unicode%(%d) "%s"
76    ["error"]=>
77    int(0)
78    ["size"]=>
79    int(1)
80  }
81}
82array(1) {
83  ["MAX_FILE_SIZE"]=>
84  %string|unicode%(1) "1"
85}
86string(1) "1"
87string(1) "3"
88