From: Dan Untenzu Date: Mon, 16 Jan 2017 11:00:39 +0000 (+0100) Subject: [BUGFIX] API: Set content type to plain text X-Git-Tag: 2.0.0~21 X-Git-Url: https://git.p6c8.net/jirafeau.git/commitdiff_plain/11233d68c69637b4c3eee55ffae78033c5dae1a9 [BUGFIX] API: Set content type to plain text Setting the content type to text only will make some browsers to ignore the utf8 charset. Set the default content type to "plain text" to deliver UTF8 and avoid errors while generating a bash script with special characters. --- diff --git a/script.php b/script.php index 3905d2f..33b8edf 100644 --- a/script.php +++ b/script.php @@ -64,7 +64,7 @@ if ($_SERVER['REQUEST_METHOD'] == "GET" && count ($_GET) == 0) } /* Lets use interface now. */ -header('Content-Type: text; charset=utf-8'); +header('Content-Type: text/plain; charset=utf-8'); check_errors ($cfg); if (has_error ())