Action
rpress_user_dashboard_address_form_fields
Fires inside the dashboard address form, before the Save Address button.
Runs in the add and edit address form of the customer dashboard, after the hidden edit_user_address_index field and before the submit button. Extra inputs are posted with the form, but core only saves its own address fields.
Example#
function my_dashboard_address_field() {
echo '<input type="text" name="my_delivery_notes" placeholder="Delivery notes">';
}
add_action( 'rpress_user_dashboard_address_form_fields', 'my_dashboard_address_field', 10, 0 );
Notes#
Saving the extra value needs a callback that runs earlier than template_redirect priority 5, where core handles the post and redirects.
Source#
Fired from:
templates/rpress-user-dashboard.php(line 485)
See also#
Was this page helpful?
