1--TEST--
2session rfc1867 sid post
3--INI--
4display_startup_errors=0
5file_uploads=1
6upload_max_filesize=1024
7session.save_path=
8session.name=PHPSESSID
9session.use_strict_mode=0
10session.use_cookies=1
11session.use_only_cookies=0
12session.upload_progress.enabled=1
13session.upload_progress.cleanup=0
14session.upload_progress.prefix=upload_progress_
15session.upload_progress.name=PHP_SESSION_UPLOAD_PROGRESS
16session.upload_progress.freq=0
17session.save_handler=files
18--EXTENSIONS--
19session
20--SKIPIF--
21<?php include('skipif.inc'); ?>
22--POST_RAW--
23Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737
24-----------------------------20896060251896012921717172737
25Content-Disposition: form-data; name="PHPSESSID"
26
27rfc1867-sid-post
28-----------------------------20896060251896012921717172737
29Content-Disposition: form-data; name="PHP_SESSION_UPLOAD_PROGRESS"
30
31rfc1867_sid_post.php
32-----------------------------20896060251896012921717172737
33Content-Disposition: form-data; name="file1"; filename="file1.txt"
34
351
36-----------------------------20896060251896012921717172737
37Content-Disposition: form-data; name="file2"; filename="file2.txt"
38
392
40-----------------------------20896060251896012921717172737--
41--FILE--
42<?php
43session_start();
44var_dump(session_id());
45var_dump(basename(__FILE__) == $_POST[ini_get("session.upload_progress.name")]);
46var_dump($_FILES);
47var_dump($_SESSION["upload_progress_" . basename(__FILE__)]);
48session_destroy();
49?>
50--EXPECTF--
51string(%d) "rfc1867-sid-post"
52bool(true)
53array(2) {
54  ["file1"]=>
55  array(6) {
56    ["name"]=>
57    string(9) "file1.txt"
58    ["full_path"]=>
59    string(9) "file1.txt"
60    ["type"]=>
61    string(0) ""
62    ["tmp_name"]=>
63    string(%d) "%s"
64    ["error"]=>
65    int(0)
66    ["size"]=>
67    int(1)
68  }
69  ["file2"]=>
70  array(6) {
71    ["name"]=>
72    string(9) "file2.txt"
73    ["full_path"]=>
74    string(9) "file2.txt"
75    ["type"]=>
76    string(0) ""
77    ["tmp_name"]=>
78    string(%d) "%s"
79    ["error"]=>
80    int(0)
81    ["size"]=>
82    int(1)
83  }
84}
85array(5) {
86  ["start_time"]=>
87  int(%d)
88  ["content_length"]=>
89  int(%d)
90  ["bytes_processed"]=>
91  int(%d)
92  ["done"]=>
93  bool(true)
94  ["files"]=>
95  array(2) {
96    [0]=>
97    array(7) {
98      ["field_name"]=>
99      string(5) "file1"
100      ["name"]=>
101      string(9) "file1.txt"
102      ["tmp_name"]=>
103      string(%d) "%s"
104      ["error"]=>
105      int(0)
106      ["done"]=>
107      bool(true)
108      ["start_time"]=>
109      int(%d)
110      ["bytes_processed"]=>
111      int(1)
112    }
113    [1]=>
114    array(7) {
115      ["field_name"]=>
116      string(5) "file2"
117      ["name"]=>
118      string(9) "file2.txt"
119      ["tmp_name"]=>
120      string(%d) "%s"
121      ["error"]=>
122      int(0)
123      ["done"]=>
124      bool(true)
125      ["start_time"]=>
126      int(%d)
127      ["bytes_processed"]=>
128      int(1)
129    }
130  }
131}
132