public function parseNewLineSeparatedBody($body)
    {
        $data = array();

        if (!$body) {
            return $data;
        }

        $parts = preg_split("/\\r?\\n/", $body);
        foreach ($parts as $str) {
            if (!$str) {
                continue;
            }

            list ($key, $value) = explode('=', $str);
            $data[$key] = $value;
        }

        return $data;
    }
public function parseNewLineSeparatedBody($body)
    {
        $data = array();

        if (!$body) {
            return $data;
        }

        $parts = preg_split("/\\r?\\n/", $body);
        foreach ($parts as $str) {
            if (!$str) {
                continue;
            }

            list ($key, $value) = explode('=', $str);
            $data[$key] = $value;
        }

        return $data;
    }
public function parseNewLineSeparatedBody ( $ body ) { $ data = array ( ) ; if ( ! $ body ) { return $ data ; } $ parts = preg_split ( "/\\r?\\n/" , $ body ) ; foreach ( $ parts as $ str ) { if ( ! $ str ) { continue ; } list ( $ key , $ value ) = explode ( '=' , $ str ) ; $ data [ $ key ] = $ value ; } return $ data ; }
Separates given string in key value parts.

@param string $body
@return array
Separates given string in key value parts .