开发者

Can't add sessionState to web.config without Error 500.19

I'm in the process of creating a new web application using classic ASP. I've done this before and have 2 similar websites that have been running for over 2 years. My problem is that the ISP I'm using has me hosted on a system running Server 2008, IIS7, and I cannot rely on session state remaining constant. I use a session variable to pass validated usernames from page to page. I know I can re-write the application to use db storage as an alternative, but I hate to have to modify a working application.

In talking with the ISP they suggested adding a sessionState variable to my web.config file and use stateserver to pass the data to a file on their system (they provided the connection string, etc.). This seems fine, but whenever I add the sessionState line to the web.config the website gets a error 500.19 with an error code of 0x8007000d.

I've tried to add a line on my local PC to simply change the session timeout as a testing methodology, but I get the same error. I'm sure it's something obvious, but I've researched the general topic and it looks like it should work? The simple web.config code is below and any suggestions would be greatfully appreciated (I'm developing a flat spot on my forehead from hitting the desk). Thanks,

Contents of web.config

<?xml version="1.0" encoding="UTF-8"?>
<configuration>

<system.webServer>

<sessionState timeout="40" />

        <defaultDocument enabled="true">
            <files>
                <clear />
                <add value="index.aspx" />
                <add value="index.asp" />
                <add value="default.htm" />
 开发者_Go百科               <add value="default.html" />
            </files>
        </defaultDocument>
        <security>
            <authentication>
                <basicAuthentication enabled="true" />
            </authentication>
        </security>
        <httpErrors errorMode="Custom">
            <remove statusCode="404" subStatusCode="-1" />
            <error statusCode="404" prefixLanguageFilePath="" path="/OaOInternal/DefaultWebs/sedoCurrent/Error404.aspx" responseMode="ExecuteURL" />
        </httpErrors>
    </system.webServer>
</configuration>


classic ASP sites don't use web.config files

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜