Rails 3. Device and Omniauth post signup redirection -
i developing user application in rails 3 , using device , omniauth signup. after user have signed using devise want either redirect page of choice or create new profile automatically user.
how can choose url redirect directly after signup (not sign in)?
thankful help!
please take here:
in application use following code redirect when user sign_up
class registrationscontroller < devise::registrationscontroller # information why controller exist: # https://github.com/plataformatec/devise/wiki/how-to:-redirect-to-a-specific-page-on-successful-sign-up-(registration) def thank_you end protected def after_sign_up_path_for(resource) "http://some.kind.of.url/hello" end def after_inactive_sign_up_path_for(resource) url_for(:controller => :registrations, :action => :thank_you) end end
Comments
Post a Comment