function _community_tags_is_tagging_view_visible in Community Tags 6
Same name and namespace in other branches
- 6.2 community_tags.module \_community_tags_is_tagging_view_visible()
- 7 community_tags.module \_community_tags_is_tagging_view_visible()
Check that tagging form is configured for display for given node in given context. Does not check user access.
Parameters
$context: Either COMMUNITY_TAGS_MODE_BLOCK, COMMUNITY_TAGS_MODE_BLOCK, or COMMUNITY_TAGS_MODE_INLINE.
3 calls to _community_tags_is_tagging_view_visible()
- community_tags_block in ./
community_tags.module - Implementation of hook_block().
- community_tags_nodeapi in ./
community_tags.module - Implementation of hook_nodeapi(). Community tags hooks should be called after taxonomy module hooks - see system weight in community_tags.install.
- _community_tags_tab_access in ./
community_tags.module - Menu access callback; Check if the user can access the 'Tags' local task on node pages.
File
- ./
community_tags.module, line 865 - Implements community tagging of nodes using a specific vocabulary for Drupal v6.x
Code
function _community_tags_is_tagging_view_visible($node, $context) {
if ($node && variable_get('community_tags_display_' . $node->type, COMMUNITY_TAGS_MODE_TAB) == $context) {
$vids = community_tags_vids_for_node($node);
if (!empty($vids)) {
return TRUE;
}
}
}