From: Christian Weiske Date: Thu, 19 Apr 2018 19:02:06 +0000 (+0200) Subject: Support multipart/form-data content type X-Git-Tag: v1.0.0~4 X-Git-Url: https://git.cweiske.de/anoweco.git/commitdiff_plain/7c5bcc1d0e398ca08e08bcc3e5e3a9f6966d959d Support multipart/form-data content type Resolves: https://github.com/cweiske/anoweco/issues/6 --- diff --git a/www/micropub.php b/www/micropub.php index c0c01b4..3cbfbe8 100644 --- a/www/micropub.php +++ b/www/micropub.php @@ -177,7 +177,9 @@ if ($_SERVER['REQUEST_METHOD'] == 'GET') { } list($ctype) = explode(';', $_SERVER['CONTENT_TYPE'], 2); $ctype = trim($ctype); - if ($ctype == 'application/x-www-form-urlencoded') { + if ($ctype == 'application/x-www-form-urlencoded' + || $ctype == 'multipart/form-data' + ) { if (!isset($_POST['action'])) { $_POST['action'] = 'create'; }