Closed (duplicate)
Project:
LoginToboggan
Version:
6.x-1.5
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
8 Oct 2009 at 08:45 UTC
Updated:
14 Oct 2009 at 20:19 UTC
I have a slight problem, i have a custom submit function i want to run after logintoboggan_user_register_submit() has run. if i set logintoboggan to do an immediate login when the user register form is submitted, logintoboggan runs its submit function, logs the user in, then redirects off after login. My custom submit does not get fired. If i turn off immediate login, my custom submit function then gets fired.
any way around this so i can keep immediate login?
Comments
Comment #1
hunmonk commentedi remember committing a fix for this issue awhile back -- here's the line in question from LT's submit handler:
$form['#submit'] = array('logintoboggan_user_register_submit') + $form['#submit'];that *should* place LT's submit handler first, and still preserve the other handlers.
also, LT's submit handler merely sets
$form_state['redirect']to trigger the redirect (even when processing a login), so any other submit handlers should be given a chance to run before the redirection happens.please double-check your code based on the above -- if you can find a bug in my logic i'm happy to fix it...
Comment #2
hunmonk commented#492486: Array merge of user_register_submit function squashes pre-defined user_register_submit functions