This module provides a tool to display structured, color-coded information about variables, similar to ColdFusion's cfdump. It supports various variable types, offers customization options for output, and allows for expandable and collapsible table cells.
Implementation of dBug for Drupal.
Features
- PHP version of ColdFusion’s cfdump.
- Outputs colored and structured tabular variable information.
- Variable types supported are: Arrays, Classes/Objects, Database and XML Resources.
- Ability to force certain types of output. Example: You can force an object variable to be outputted as an array type variable.
- Stylesheet can be easily edited.
- Table cells can be expanded and collapsed.
The main modification is to return a render array instead of echo.
dBug page: https://github.com/ospinto/dBug
Usage:
$dbug_variable = Dbug::debug($variable);
$output['#attached']['library'][] = 'dbug/dbug';
$output['variable'] = [
'#type' => 'markup',
'#markup' => $dbug_variable,
];Change the $variable for the variable you want to show the debug information.
Ask your assistant about dBug for Drupal
Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works
Depends on
Dependencies of the latest stable release
No dependencies recorded for this project.
Required by
Tracked projects that depend on this one
No tracked projects depend on this one yet.