Return to Snippet

Revision: 3937
at October 4, 2007 12:55 by marcoba

Updated Code
<pre><?php print htmlentities(print_r($vars_data, 1)) ?></pre>

Revision: 3936
at October 4, 2007 11:10 by marcoba

Initial Code
<?php drupal_set_message('<pre>'. print_r($node, TRUE) .'</pre>'); ?>

Initial URL

Initial Description
Drupal snippet: outputs all theming variables of a content type or page. Add to template.php the following function:

function _phptemplate_variables($hook, $vars) {
  return array('vars_data' => $vars);

then add the snippet to the relative node.tpl.php file.

Initial Title
Drupal: output theme variables

Initial Tags
php, drupal

Initial Language