pe/component-form-data

Form data component allow to parse raw form data body for non POST requests

v1.0.0 2017-12-06 10:26 UTC

This package is auto-updated.

Last update: 2022-11-05 15:36:41 UTC


README

This component allow to parse raw form data body for non POST requests

Installation

php composer.phar require pe/component-form-data:1.0.0

Usage

// Parse data
$data = new FormData(
    $_SERVER['CONTENT_TYPE'],
    file_get_contents('php://input')
);

// Get $_FILES compatible array
$data->getFILES()

// Get $_POST compatible array
$data->getPOST()