Discussion Forums
- Topic List
- Most Recent Posts
- Sign In for more options
I know that acts_as_authenticated sets up the email as an observer for you, but I'd recommend in favor of removing the observer and sending the email directly from the controller when the user is created. Using observers to send emails obscures code, and brings up the sort of logic issues you are dealing with.
Hello,
I have a beta testing program for a multilingual webapp using globalite. People register on the website in english or in french.
I use a UserObserver from acts_as_authenticated plugin that send an email with an activation code to validate registration. Depending on which language... I need to send the good email.
Using the after_create within UserObserver, is there a way to pass the language variable in the model or do I need to setup this in the controller?
Or is there any other way to achieve this beside sending a multilingual email hehe.
Thx a lot for your time and advises.
Hugues
