我有converted一个简单的HTML网站到Web应用程序 enabled表单身份验证.aspx页面现在需要login 但是旧的.html页面仍然可以直接打开而无需登录 我必须将所有页面转换为.aspx,还是可以强制登录.html页面?
Web.Config中:
<?xml version="1.0" encoding="utf-8"?>
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
<authentication mode="Forms">
<forms loginUrl="login.aspx" name=".aspxFormsAuthentication" cookieless="AutoDetect" protection="All" timeout="30" path="/" requireSSL="false" slidingExpiration="true" defaultUrl="index.html">
</forms>
</authentication>
<authorization>
<deny users="?" />
</authorization>
</system.web>
<appSettings>
<add key="ValidationSettings:UnobtrusiveValidationMode" value="None" />
</appSettings>
</configuration>
答案 0 :(得分:0)
位置元素没有帮助。
这似乎是不可能的,我确实需要将需要登录的页面转换为.aspx页面。