Sorry if I fail to understand the essence of the problem, but to me, it looks like an artificial one. You have a form with authentication data, post it using "POST" method, and, on successful authentication, why do you think you should reload the same very page? You can go out off this page and send some other pages in response, using the
form
attribute
action
. On the other pages, you can only have "Logout", no need to have authentication form at all, until session timeout or other cases of closed session.
Well, on more complex site (look at the top of any page of CodeProject) you really might need to permanently keep login/logout part with the form and show/hide and/or enable/disable some elements, but why this can be a problem?
After all, if you need to hide a control, you can use and modify
visibility
VSS property. Please see the description of the property, pay attention for the JavaScript use:
http://www.w3schools.com/cssref/pr_class_visibility.asp[
^].
—SA