Is there a module which redirects Anonymous users to user login form after submitting node form and saves the node only when user successfully logs into data?

Will I have to do it by $_SESSION if theres no module supporting the above functionality?

EDIT:- For anonymous user, I want to show node add form of custom content type. But when anonymous user fills all information and clicks submit, the control should go to login form and after user logs in then only the node should get saved with a confirmation message. So is there an existing module for above requirement.

EDIT2:- If the user doesnt logs in then the data should not be saved. So the data should get saved only when the user logs into the system after he is redirected to log in form. Even after he logs into the system after two days, then the data should not get saved.

  • Is good to provide more information to have a good answer. You really should tell what Drupal version, 6, 7, 8? – sanzante Dec 3 '15 at 18:36
  • can you be more specific? – Adrian Cid Almaguer Dec 3 '15 at 18:40
  • I have updated the question, please check. – Villie Dec 4 '15 at 6:04
  • What should happen with the submitted data if the login is cancelled (eg window is closed) or fails (eg: forgot password)? And would it be ok to "save" such failed submission somewhere in the future after the author ever actually gets logged in? Please EDIT your question to clarify all this (and add a "done" comment afterwards). Depending on your clarifications I might have a solution for your question ... – Pierre.Vriens Dec 4 '15 at 7:22
  • Please check the updated question. – Villie Dec 4 '15 at 7:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.