phpmyadmin/libraries/classes/Controllers/PhpInfoController.php
Maurício Meneghini Fauth 50bc4ab37f Remove useless PHP docs for functions
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
2020-01-20 13:20:01 -03:00

30 lines
636 B
PHP

<?php
/**
* phpinfo() wrapper to allow displaying only when configured to do so.
*
* @package PhpMyAdmin\Controllers
*/
declare(strict_types=1);
namespace PhpMyAdmin\Controllers;
/**
* phpinfo() wrapper to allow displaying only when configured to do so.
*
* @package PhpMyAdmin\Controllers
*/
class PhpInfoController extends AbstractController
{
public function index(): void
{
global $cfg;
$this->response->disable();
$this->response->getHeader()->sendHttpHeaders();
if ($cfg['ShowPhpInfo']) {
phpinfo(INFO_GENERAL | INFO_CONFIGURATION | INFO_MODULES);
}
}
}