function taxonomy_menu_taxonomy_menu_options in Taxonomy menu 6.2
Same name and namespace in other branches
- 6.3 taxonomy_menu.module \taxonomy_menu_taxonomy_menu_options()
- 7 taxonomy_menu.module \taxonomy_menu_taxonomy_menu_options()
Implementation of hook_taxonomy_menu_options().
Return value
array Uses the value to set the variable taxonomy_menu_<value>_$vid $options[value] default - optional. this is what will be used if the varialbe is not set. if empty then FALSE is used #title - required. any other form element
File
- ./
taxonomy_menu.module, line 916 - It Generates menu links for all selected taxonomy terms
Code
function taxonomy_menu_taxonomy_menu_options() {
$options['sync'] = array(
'#title' => t('Synchronise changes to this vocabulary'),
'#description' => t('Every time a term is added/deleted/modified, the corresponding menu link will be altered too.'),
'default' => TRUE,
);
$options['display_num'] = array(
'#title' => t('Display number of items'),
'#description' => t('Display the number of items per taxonomy terms. Will not show up for vocabulary menu items.'),
'default' => FALSE,
);
$options['hide_empty_terms'] = array(
'#title' => t('Hide empty terms'),
'#description' => t('Hide terms with no items attached to them.'),
'default' => FALSE,
);
$options['voc_item'] = array(
'#title' => t('Add item for vocabulary'),
'#description' => t('Shows the vocabulary name as the top level menu item of the taxonomy menu.'),
'default' => TRUE,
);
$options['expanded'] = array(
'#title' => t('Auto expand menu items'),
'#description' => t('Automatically show all menu items as expanded.'),
'default' => TRUE,
);
$options['voc_name'] = array(
'#type' => 'textfield',
'#title' => t('Custom name for vocabulary item'),
'#description' => t('Changes the name of the vocabulary item (if enabled above). Leave blank to use the name of the vocabulary.'),
'default' => '',
);
$options['display_descendants'] = array(
'#title' => t('Display descendants'),
'#description' => t('Changes the default path to taxonomy/term/tid+tid+tid for all terms thave have child terms.'),
'default' => FALSE,
);
$options['blank_title'] = array(
'#title' => t('Do not create title link attribute.'),
'#description' => t("Do not create the link['options']['attributes']['title'] on the link array."),
'default' => FALSE,
);
$options['end_all'] = array(
'#title' => t("Use 'all' at the end of URL"),
'default' => FALSE,
'#description' => t('This changes tid+tid+tid to "All" in term when <em>Display descendants</em> has been selected.<br />Only used if <em>Menu path type</em> is "Default path".<br />Works with default taxonomy page.'),
);
$options['depth_limit'] = array(
'#title' => t('Depth limit'),
'#type' => 'textfield',
'#description' => t('Limit how many levels of the taxonomy tree to process. Useful if you have a very large tree of taxonomy terms, and only want to provide a menu for the first two levels. 0 for no limit.'),
'#size' => 5,
'default' => 0,
);
return $options;
}