-
Get a List of Top-level Taxonomy Terms
Quick Tip: Getting a list of taxonomy terms is easy using a view (type: Taxonomy). Trying to get only terms at the highest level is a bit trickier. One method I came up with is to add a Taxonomy: Parent term argument on the view. The key is to tell the argument to Provide default argument of PHP Code and set the value to return 0;
The result is that only top-level terms (terms without parents) are returned.
-
Showing a nodeasblock block as full content instead of teaser
By default, the Node As Block module displays a node in teaser mode. If you wish to show the full content, add the following to your template.php file. (note I’ve also added an edit link for good measure)
123456789function mytheme_preprocess_nodeasblock(&$vars) {$node = $vars['node'];$vars['content'] = node_view(node_load($node->nid), FALSE, TRUE, TRUE);// Add an edit linkif (node_access('update', $node)) {$vars['edit_link'] = l('['. t('edit') .']', 'node/'. $node->nid .'/edit', array('title' => t('Edit')));}}