Esc
API Index — Namespaces, Packages, Reports, Indices
PhpInfo
in package
FinalYes
Renders phpinfo() as a self-contained HTML document, restoring Apache+mod_php
parity for the CLI SAPI (which otherwise emits a plain-text key => value dump).
Pure renderer: no echo, no global writes. The uopz override target
\ZealPHP\phpinfo() echoes render() and returns true.
Robustness: a diagnostics page must never fatal. Request-variable collection
is guarded so render() works in any context (request handler, CLI, unit test).
Table of Contents
Properties
- $moduleText : string
- Boot-captured native
phpinfo(INFO_MODULES)text, primed once per worker.
Methods
- primeModuleText() : void
- Store the native module-section text captured before the uopz override.
- render() : string
- collectRequestVars() : array<string, array<int|string, mixed>>
- document() : string
- e() : string
- iniField() : string
- openswooleVersion() : string
- renderConfiguration() : string
- renderGeneral() : string
- renderModules() : string
- renderVariables() : string
- section() : string
- stringify() : string
- styles() : string
- toArray() : array<int|string, mixed>
Properties
$moduleText
Boot-captured native phpinfo(INFO_MODULES) text, primed once per worker.
private
static string
$moduleText
= ''
Methods
primeModuleText()
Store the native module-section text captured before the uopz override.
public
static primeModuleText(string $text) : void
Parameters
- $text : string
render()
public
static render([int $flags = INFO_ALL ][, array<string, array<int|string, mixed>>|null $requestVars = null ]) : string
Parameters
- $flags : int = INFO_ALL
-
INFO_*bitmask (matches nativephpinfo()). - $requestVars : array<string, array<int|string, mixed>>|null = null
-
Test seam:
['_GET'=>..., '_POST'=>..., '_COOKIE'=>..., '_SERVER'=>...]. Null pulls fromG.
Return values
stringcollectRequestVars()
private
static collectRequestVars() : array<string, array<int|string, mixed>>
Return values
array<string, array<int|string, mixed>>document()
private
static document(string $body) : string
Parameters
- $body : string
Return values
stringe()
private
static e(string $s) : string
Parameters
- $s : string
Return values
stringiniField()
private
static iniField(array<string|int, mixed> $info, string $key) : string
Parameters
- $info : array<string|int, mixed>
- $key : string
Return values
stringopenswooleVersion()
private
static openswooleVersion() : string
Return values
stringrenderConfiguration()
private
static renderConfiguration() : string
Return values
stringrenderGeneral()
private
static renderGeneral() : string
Return values
stringrenderModules()
private
static renderModules() : string
Return values
stringrenderVariables()
private
static renderVariables(array<string, array<int|string, mixed>> $vars) : string
Parameters
- $vars : array<string, array<int|string, mixed>>
Return values
stringsection()
private
static section(string $title, array<string, string> $rows) : string
Parameters
- $title : string
- $rows : array<string, string>
Return values
stringstringify()
private
static stringify(mixed $v) : string
Parameters
- $v : mixed
Return values
stringstyles()
private
static styles() : string
Return values
stringtoArray()
private
static toArray(mixed $v) : array<int|string, mixed>
Parameters
- $v : mixed