I am using domain access module. And i need to create a taxonomy term and set it to specific domain programatically. So i have used "domain access entity". How to set domain with "taxonomy_term_save". Can anyone help????
I am using domain access module. And i need to create a taxonomy term and set it to specific domain programatically. So i have used "domain access entity". How to set domain with "taxonomy_term_save". Can anyone help????
Comments
Comment #2
ciss commentedSupport requests are never critical. Please read Priority levels of issues.
Comment #3
s5nelson commentedOnly through a bunch of trial and error have I been able to figure this out, and I still receive Warning messages even though it works. Here's what I did:
I believe that this is a bug in the system since I'm getting these errors whenever I try to add a new Taxonomy Term through the UI:
Warning: reset() expects parameter 1 to be array, null given in domain_entity_field_widget_form() (line 491 of /var/www/html/sites/all/modules/domain_entity/domain_entity.module).
Warning: mail(): Could not execute mail delivery program '/usr/sbin/sendmail -t -i' in domain_entity_sendDebugToMyself() (line 830 of /var/www/html/sites/all/modules/domain_entity/domain_entity.module).
Warning: in_array() expects parameter 2 to be array, null given in domain_entity_field_widget_form() (line 495 of /var/www/html/sites/all/modules/domain_entity/domain_entity.module).
Warning: in_array() expects parameter 2 to be array, null given in domain_entity_field_widget_form() (line 498 of /var/www/html/sites/all/modules/domain_entity/domain_entity.module).
So essentially you would create the Domain Taxonomy Field (shown above), then set the field value to the Domain ID you wanted. To get the Domain ID of the current Domain, you would use:
Hopefully this helps!
Comment #4
bohartD7 reached its EOL back in January 2025, and there is no active release for D7 for this module.
Neither development nor support is planned for D7.
All D7-related issues (especially those with ~10 years of inactivity) are marked as outdated in a bunch.
If/once the issue still arises in D11+ versions, please create a follow-up issue.
Thanks!