我正在尝试将网页添加到已经放在 IIS 7.5 上的网站。我在互联网上搜索试图更改 .config 文件、添加 dll 文件的解决方案。当我将其作为自己的网站运行时,该网页运行良好,但当我在已建立的网站上设置其自己的 url 时会产生错误。
这是错误:
"The value for the 'compilerVersion' attribute in the provider options must be 'v4.0'
or later if you are compiling for version 4.0 or later of the .NET Framework. To
compile this Web application for version 3.5 or earlier of the .NET Framework,
remove the 'targetFramework' attribute from the <compilation> element of the
Web.config file. Description: An unhandled exception occurred during the execution
of the current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Configuration.ConfigurationErrorsException: The value for
the 'compilerVersion' attribute in the provider options must be 'v4.0' or later if
you are compiling for version 4.0 or later of the .NET Framework. To compile this
Web application for version 3.5 or earlier of the .NET Framework, remove the
'targetFramework' attribute from the <compilation> element of the Web.config file."