diff options
Diffstat (limited to 'mod/diagnostics/actions/download.php')
| -rw-r--r-- | mod/diagnostics/actions/download.php | 35 |
1 files changed, 15 insertions, 20 deletions
diff --git a/mod/diagnostics/actions/download.php b/mod/diagnostics/actions/download.php index 3f7181f27..97775c92e 100644 --- a/mod/diagnostics/actions/download.php +++ b/mod/diagnostics/actions/download.php @@ -1,23 +1,18 @@ <?php - /** - * Elgg diagnostics - * - * @package ElggDiagnostics - * @author Curverider Ltd - * @link http://elgg.com/ - */ +/** + * Elgg diagnostics + * + * @package ElggDiagnostics + */ - admin_gatekeeper(); - - $output = sprintf(elgg_echo('diagnostics:header'), date('r'), $_SESSION['user']->name); - $output = trigger_plugin_hook('diagnostics:report', 'system', null, $output); - - header("Cache-Control: public"); - header("Content-Description: File Transfer"); - header('Content-disposition: attachment; filename=elggdiagnostic.txt'); - header("Content-Type: text/plain"); - header('Content-Length: '. strlen($output)); +$output = elgg_echo('diagnostics:header', array(date('r'), elgg_get_logged_in_user_entity()->name)); +$output = elgg_trigger_plugin_hook('diagnostics:report', 'system', null, $output); - echo $output; - exit; -?>
\ No newline at end of file +header("Cache-Control: public"); +header("Content-Description: File Transfer"); +header('Content-disposition: attachment; filename=elggdiagnostic.txt'); +header("Content-Type: text/plain"); +header('Content-Length: ' . strlen($output)); + +echo $output; +exit; |
