adudjandaniel/php_dump

Beautify variable dumping in php

v1.1 2019-10-19 15:34 UTC

This package is auto-updated.

Last update: 2024-05-25 03:47:03 UTC


README

Being used to the fancy dump Adobe Coldfusion uses, I can hardly make sense of the raw dumping in php; I need something similar.

Usage:

  • composer require adudjandaniel/php_dump
  • require_once /path/to/autoload.php (Add to php scripts)
  • use namespace PhpDump\Dump
  • Dump::php_dump(variable_name [, label])

Functionality (so far):

  • Dumping
    • basic types (integer, boolean, float, string)
    • indexed arrays
    • associative array
  • Toggling display of values.
    Click on the key of the value to toggle it's display.

The method php_dump() takes two parameters:

  1. variable name (required)
  2. label (optional)

Check these outputs:

dump_1.pngdump_2.png