Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Drupal 5
- // Show block if a node has a specific taxonomy term
- $show_block = FALSE;
- if ( arg(0) == "node" && is_numeric(arg(1)) ) {
- $node = node_load(arg(1));
- $section_term_id = 1334; // replace this to the corresponding term id
- $show_block = ( is_array($node->taxonomy) && in_array($section_term_id, array_keys($node->taxonomy)) );
- }
- return $show_block;
- ?>
Add Comment
Please, Sign In to add comment