function _hs_taxonomy_views_parse_vocabulary_id_from_id in Hierarchical Select 5.3
Given an id of the form "term_node_1.tid", with 1 the vid, get the vid.
Return value
When no valid id was given, FALSE, otherwise the vid.
1 call to _hs_taxonomy_views_parse_vocabulary_id_from_id()
- hs_taxonomy_views_hierarchical_select_config_info in modules/
hs_taxonomy_views.module - Implementation of hook_hierarchical_select_config_info().
File
- modules/
hs_taxonomy_views.module, line 436 - Implementation of the Hierarchical Select API for the Taxonomy module's Views exposed filters.
Code
function _hs_taxonomy_views_parse_vocabulary_id_from_id($id) {
$vid = FALSE;
if (preg_match("/term_node_(\\d+)\\.tid/", $id, $matches)) {
$vid = $matches[1];
}
return $vid;
}