Output contents of a node

To display all of a nodes content, so you can pick and choose what you’re going to be displaying on the page use this:

<pre><?php print_r($node); ?></pre>

Leave it like that and you’ll get all the arrays and child arrays that are available for that node.

If you want it to look a little prettier, wrap the PHP statement in <pre> tags and you’ll get a nicely formatted list instead.

» Coding · Drupal

Add your comment

Latest tweets
  • Sorry, twitter is down