Under Construction
This documentation page is currently under construction. Connections provides hundreds of actions and filters. If you have a specific requirement that is not listed below, please feel free to get in touch with us, and we will promptly add the documentation for the relevant hook.
Actions
- Many to come; please get in touch with us if you need documentation for a specific action hook.
Filters
cn_family_relation_options
Use this filter to add and remove the family relation options.
add_filter(
'cn_family_relation_options',
static function ( $options ) {
// Remove the "Husband" option.
unset( $options['husband'] );
// Add a "Head of Household" option.
$options['head-of-household'] = 'Head of Household';
return $options;
}
);
cn_address_options
This filter supplies an array containing the core address types. The array key is the address type ID, and the array value is the address label.
The address key ID needs to be in all lowercase using underscores in places of spaces, and the address label can be any text that you wish.
The following example code adds two new address types named “Shipping” and “Receiving”.
add_filter(
'cn_address_options',
static function ( $options ) {
$options['shipping'] = 'Shipping';
$options['receiving'] = 'Receiving';
return $options;
}
);
cn_phone_options
This filter supplies an array containing the core phone types. The array key is the phone type ID, and the array value is the phone label.
The phone key ID needs to be in all lowercase using underscores in places of spaces, and the phone label can be any text that you wish.
The following example code adds two new phone types named “Shipping” and “Receiving”.
add_filter(
'cn_phone_options',
static function ( $options ) {
$options['shipping'] = 'Shipping';
$options['receiving'] = 'Receiving';
return $options;
}
);
cn_email_options
This filter supplies an array containing the core email types. The array key is the email type ID, and the array value is the email label.
The email key ID needs to be in all lowercase using underscores in places of spaces, and the email label can be any text that you wish.
The following example code adds two new phone types named “Primary” and “Secondary”.
add_filter(
'cn_email_options',
static function ( $options ) {
$options['primary'] = 'Primary';
$options['secondary'] = 'Secondary';
return $options;
}
);
