How can I intercept Drupal User Registration after it has passed all validations?

Posted by Senthil on Stack Overflow See other posts from Stack Overflow or by Senthil
Published on 2010-05-18T12:16:06Z Indexed on 2010/05/21 12:50 UTC
Read the original article Hit count: 258

Filed under:
|

Hi,

I am using Drupal 6.16

In the user registration module, I want to hook in AFTER all validations have been made and the row is about to be inserted. Here, I want to run my business logic. If my business logic fails, the drupal registration should be stopped. I can do this by setting an error in the form. If it succeeds, drupal registration SHOULD proceed and complete.

I decided to use the validate operation in hook_user. But it is possible for drupal registration to be stopped at the validation phase itself, by some other module that is run after mine. What I want is, when my business logic succeeds, the drupal registration MUST succeed.

Which hook and operation should I use so that I can intercept just before the drupal user info insert/update and after all validations have succeeded?

© Stack Overflow or respective owner

Related posts about drupal-6

Related posts about hook