I'd like to assist implementing a new PHP procedure called PHP Variable Hunter (in Sandbox). It specifically searches for array members containing ‘needle’, more precisely than dpm or krumo. It does the hunting for you.
Use it like this:
$results = pvh($arraytosearch, ‘needle’, TRUE); // last parm is optional; specifies exact match (default FALSE). $results is also optional.
It looks through the array tree structure for the needle and prints the results to the screen like this:
$ArraySearch[content][leader][leader_first]->block_7[#contextual_links][block][1]; == block
Results are in exact PHP format, with object references included.
For debug sessions the array $results contains the variables in the array, so developers can find and examine the array without leaving the debug session.
- I’m asking if you want this routine added to the debug module. It is not Drupal version specific.
Sandbox location: https://drupal.org/sandbox/jeoware/2023153
I'll assist implementation.
Comments
Comment #0.0
jeoware commentedAdded hatsto request
Comment #1
jeoware commentedComment #2
kscheirerWhy is this duplicate?
I've reviewed your module, and I think it would be a good addition to the Devel project, especially if implemented as a Drush command. If the maintainers of Devel agree, could you provide a patch file here that implements this?
Comment #3
jeoware commentedI'd love to include this module in the Devel module and am waiting for feedback from devel module developers before progressing further.
Comment #4
salvisI'm closing this one because the newer one has a screenshot: #2069003: Adding PHP Varible Hunter to Devel
Comment #4.0
salvisNew version in Sandbox.