Something
public text v1 · immutable/**
* Create a vocabulary with a tree of terms beneath it, optionally specifying the module that will handle
* the paths for that taxonomy.
*/
function profile_helper_make_vocabulary($vocabulary, $module = NULL) {
taxonomy_vocabulary_save($vocabulary);
if (isset($vocabulary['terms'])) {
foreach($vocabulary['terms'] as $term) {
$term['vid'] = $vocabulary['vid'];
taxonomy_save_term($term);
}
}
}