Last active
December 14, 2015 17:49
-
-
Save wshayes/5124830 to your computer and use it in GitHub Desktop.
Drupal Debugging Snippets
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Needs Devel Module - shows all defined variables on page | |
| <?php | |
| dpm( get_defined_vars() ); | |
| ?> | |
| Viewing Node Data Structures | |
| The drush command line and/or the Devel module's Execute PHP code block can be used to display data structures. Here are sample commands for displaying a node object: | |
| drush: drush php-eval "print print_r(node_load(12), 1)" | |
| PHP block: dpr(node_load(12)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment