views:

14

answers:

1

Hello

I am writing a wordpress module that will need to re-direct the registration process to a checkout. I have the checkout working, and I have added the extra options I need to the normal Wordpress registration screen.

I need some pointers on how to intercept the registration process before anything is committed to the database. After the checkout phase I need to then re-start the proccess and finish it.

A: 

Check out wp-login.php - that contains pretty much all the login and registration functions.

You'll see on line 300 (as of 3.0), you can hook onto the action register_post, which is called just before WP attempts to save the new user to the DB;

function my_register_post($sanitized_user_login, $user_email, $errors)
{
    // do your stuff!
}
add_action('register_post', 'my_register_post', 10, 3);
TheDeadMedic