ToolbarInjector
API reference › Debug Core › Toolbar › ToolbarInjector
Places rendered toolbar markup inside an already-rendered HTML response.
Methods
Section titled “Methods”| Method | Description | Defined by |
|---|---|---|
inject() static | Injects toolbar markup immediately before the final closing body tag. | ToolbarInjector |
Method details
Section titled “Method details”inject()
Section titled “inject() ”public static function inject(string $html, string $toolbar): stringInjects toolbar markup immediately before the final closing body tag.
Parameters
| Parameter | Type | Description |
|---|---|---|
$html | string | Response HTML. |
$toolbar | string | Rendered toolbar markup. |
Returns
string: HTML containing the toolbar, appended when no closing body tag exists.