TIP: Use Markdown or, <pre> for multi line code blocks / <code> for inline code.
These forums are read-only and for archival purposes only!
Please join our new forums at discourse.kohanaframework.org
Request body parser for PUT & DELETE: data()
  • Hi, I've been using this extension to the Request, which parses the body request when using methods others than POST and GET (PUT & DELETE) and gives a method to getting information as post() and query(); I've read a couple of threads related to the parsing of the body regarding this methods; but I couldn't find any about asking this as a new feature; but it might be duplicated; sorry and dismiss if it's the case.

    class Request extends Kohana_Request {

    public static function data()
    {
        $data = array();
        parse_str( Request::current()->body(), $data );
        return( $data );
    }
    

    }