barcellano-envoy/parse_multipart_form_put

There is no license information available for the latest version (dev-master) of this package.

PHP library for handling multipart form data for put requests

dev-master 2014-11-11 22:28 UTC

This package is not auto-updated.

Last update: 2025-03-25 04:57:48 UTC


README

Package to parse multipart form data from a PUT request. Useful for replacing photos using a RESTful api.

Example:

$put_data = array();
Envoy\MultipartForm\Processer::parse($put_data);
print_r($put_data);

OR

$put_data = array();
Envoy\MultipartForm\Processer::parse($put_data, $RAW_INPUT);
print_r($put_data);

Not really tested very much. Let me know if you run into any issues with github issues.

Results:

Key is form name

Array
(
    [test1] => Field 1 text
    [test2] => Field 2 Text
)

Or with a file

Array
(
    [test1] => Field 1 text
    [test2] => Field 2 Text
    [files] => Array
        (
            [0] => Array
                (
                    [form_name] => file1
                    [file_name] => 712.png
                    [content-type] => image/png
                    [file] => �PNG
�

IHDR�����>a�9tEXtSoftwareAni...