Tutorial how to create member login and logout form in Umbraco MVC
Hi
Just in case anyone is looking for a simple tutorial for creating a login form with logout button in umbraco using MVC I've just published an article on it on my blog.
Since i am new to Umbraco and MVC, I have one doubt and not sure how it works and i.e returnURL. Basically I am looking for a something where i want to navigate to other page once i am successfully logged in..
I used return View("History"); in controller but there are two problem with this
1. URL doesnt change from ~/login to ~/History
2. If i am reading any records from @Umbraco.Media then it doesnt work once i navigate.
Hi @Paul, I viewed your tutorial and it looks great. Is there a way to add custom content from the back-end for each individual user? For example, adding an ability for a back-end user to upload an invoice specific to a single user whereby they can view such an invoice when logged in?
Tutorial how to create member login and logout form in Umbraco MVC
Hi Just in case anyone is looking for a simple tutorial for creating a login form with logout button in umbraco using MVC I've just published an article on it on my blog.
http://www.codeshare.co.uk/blog/tutorial-how-to-create-member-login-and-logout-form-in-umbraco-mvc/
Please let me know if you have any questions or you spot any errors.
Thanks
Paul
Awesome, can probobly be very helpful to a lot of people! Great job! :)
Thanks Dennis
Thank you Sir!
No problem. I'm glad you found it useful.
Great blog,
Since i am new to Umbraco and MVC, I have one doubt and not sure how it works and i.e returnURL. Basically I am looking for a something where i want to navigate to other page once i am successfully logged in..
I used return View("History"); in controller but there are two problem with this 1. URL doesnt change from ~/login to ~/History 2. If i am reading any records from @Umbraco.Media then it doesnt work once i navigate.
Regards, Sourav
I keep coming back to this when I can't find a project that has this implemented...
One small thing. You don't seem to set the returnUrl. I fixed this by updating the BeginUmbracoForm for the login, to this
Thanks Sven, I’ll update the post
Hi @Paul, I viewed your tutorial and it looks great. Is there a way to add custom content from the back-end for each individual user? For example, adding an ability for a back-end user to upload an invoice specific to a single user whereby they can view such an invoice when logged in?
Great example. Worth to update it to support Umbraco 8 by replacing UmbracoTemplatePage with UmbracoViewPage.
Instead of a logout form, how can I go direct to logout by clicking a button in the header?
Don't think you can do it without a form, but that doesn't mean you cant put a small form in your header.
Hi Connie,
You could link to your login form:
/login?signout=true
And then at the top of your login page have:
Would this work in v8 as well?
I get errors in the _LogOut partial view such as
&
is working on a reply...