I'd like to set a vocabulary's translation mode to "translate" (I18N_MODE_TRANSLATE") programmatically in my module. I've looked at the API and can't find a way to do this... I thought this would set the mode:
$taxonomy_name = 'time_category';
$taxonomy_vocab = taxonomy_vocabulary_machine_name_load($taxonomy_name);
i18n_taxonomy_vocabulary_mode($taxonomy_vocab->vid, I18N_MODE_TRANSLATE);
But it doesn't seem to work...
Comments
Comment #1
hillaryneaf commentedComment #2
atulkamboj commentedTry the below code and it will set the mode to 'Translate':
Comment #3
hillaryneaf commentedThanks ;)
Comment #4
kajalkiran commentedHi,
My task was to set all the vocabularies to i18n_mode = 1. So, I was able to do this by
Hope this helps !!