Hi,
I have conducted a search on the forum just to see if anybody else has experienced this problem and i couldn't find any similar posts. Here goes. I have set up a basic Forms autheentication. See below:
The web.config file:Code:private void Button1_Click(object sender, System.EventArgs e) { if (txtUsername.Text == "????" && txtPassword.Text == "?????") { FormsAuthentication.RedirectFromLoginPage("LoggedIn", false); } else { lblLoggedin.Text = "Login falied"; } }
Now this all works on my localhost, however as soon as i upload my webconfig file onto my webserver i get the following error:Code:<configuration> <system.web> <customErrors mode="Off"/> <authentication mode="Forms" /> <authorization> <deny users="?" /> </authorization> </system.web> </configuration>
I am totally stumped to whats wrong here?Code:RUNTIME ERROR <!-- Web.Config Configuration File --> <configuration> <system.web> <customErrors mode="Off"/> </system.web> </configuration> <!-- Web.Config Configuration File --> <configuration> <system.web> <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/> </system.web> </configuration>
As always any help is greatly appreciated.




Reply With Quote