Filter
rpress_account_hub_address_labels
On this page
Filters the address label choices on the checkout save-address option.
Runs when the checkout renders the Save this address for next time option for a logged-in customer using the delivery service. The labels fill the label dropdown, and the selected label is posted as rpress_save_address_label.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$labels | string[] | Label choices. Default: Home, Work, Other (translated). |
Return value#
string[]. Label choices.
Example#
add_filter( 'rpress_account_hub_address_labels', 'my_address_labels', 10, 1 );
function my_address_labels( $labels ) {
$labels[] = __( 'Office', 'my-plugin' );
return $labels;
}
Source#
Applied in:
includes/features/account-hub/frontend.php(line 188), inrpress_account_hub_checkout_save_option()
Was this page helpful?
