shopp_customer_registered

This action is called at the end of the customer registration process.

add_action('shopp_customer_registered', [callback] );

@param Customer $Customer The Customer account object.

Description

This action is called at the end of the customer registration process, just before the customer is logged-in. The Customer object is passed to the the callback function as a parameter.

Note: The customer record is saved before this action is called, so ‘$Customer->id’ is available. See shopp_customer_registration for an action called at the beginning of the registration process.

Example

// This example shows how the action might be used to save the 
// value of a select input to customer meta data.

add_action('shopp_customer_registered', 'shopp_customer_registered_function');

function shopp_customer_registered_function ( $Customer ) {
  $ctitle = sanitize_text_field($_POST['customer-title']);
  if ($ctitle) {
    shopp_set_meta($Customer->id, 'customer', 'ctitle', $ctitle, 'meta');
  }
}

See Also

You must be logged in to post a comment.

© Ingenesis Limited. Shopp™ is a registered trademark of Ingenesis Limited.

Skip to toolbar