public function saveGroups()
    {
        // Save group names as new array
        $event_groups = array();
        if (!empty($this->groups) && is_array($this->groups)) {
            foreach ($this->groups as $group) {
                $event_groups[] .= $group['name'];
            }
        }
        wp_set_object_terms($this->ID, $event_groups, 'event_groups', false);
    }
public function saveGroups()
    {
        // Save group names as new array
        $event_groups = array();
        if (!empty($this->groups) && is_array($this->groups)) {
            foreach ($this->groups as $group) {
                $event_groups[] .= $group['name'];
            }
        }
        wp_set_object_terms($this->ID, $event_groups, 'event_groups', false);
    }
public function saveGroups ( ) { // Save group names as new array $ event_groups = array ( ) ; if ( ! empty ( $ this -> groups ) && is_array ( $ this -> groups ) ) { foreach ( $ this -> groups as $ group ) { $ event_groups [ ] .= $ group [ 'name' ] ; } } wp_set_object_terms ( $ this -> ID , $ event_groups , 'event_groups' , false ) ; }
Saves groups as taxonomy terms
@return void
Saves groups as taxonomy terms