From c083e1e49af4902d15173d412feebd8b86a616ee Mon Sep 17 00:00:00 2001 From: jim-p Date: Mon, 29 Jan 2018 12:24:25 -0500 Subject: [PATCH] Fix a potential encoding issue in diag_system_activity.php. Fixes #8300 --- src/usr/local/www/diag_system_activity.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/usr/local/www/diag_system_activity.php b/src/usr/local/www/diag_system_activity.php index 3c7d077eeb..00993d0e08 100644 --- a/src/usr/local/www/diag_system_activity.php +++ b/src/usr/local/www/diag_system_activity.php @@ -32,6 +32,7 @@ $pgtitle = array(gettext("Diagnostics"), gettext("System Activity")); if ($_REQUEST['getactivity']) { $text = `/usr/bin/top -aHS | /usr/bin/cut -c1-105`; + header('Content-Type: text/plain; charset=UTF-8'); echo $text; exit; } @@ -69,7 +70,7 @@ events.push(function() { // Deal with the results of the above ajax call ajaxRequest.done(function (response, textStatus, jqXHR) { - $('#xhrOutput').html(response); + $('#xhrOutput').text(response); ajaxbusy = false; });