'When user click the login button on the home page a session starts and the user is redirect to the same homepage with the form now gone

this is a .net core MVC app and I want that when a user enters his/her identity card number on the homepage then they are redirected to the same page without the form this time and a session is also created against that identity card number. enter image description here



Solution 1:[1]

You should add an if on the form with some methods in your controller in order to control if session is saved or not. something like : IsUserConnected and use an ng-if=IsUserConnected" in the top of your form declaration.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Bechir Anoir Chabchoub