atlas网站的webconfig配置文件
2009-08-20 14:50
183 查看
使用Atlas Hands-On-Lab VSI模板时,您可能不见得会注意到在项目角落中有一个隐形人,它就是Web.config配置文件,与一般的项目配置文件不同它里面加入了Atlas运作所必须的相关设定,以下是其组态设定:
<?xml version="1.0"?>
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
/Windows/Microsoft.Net/Framework/v2.x/Config
-->
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<!--
The configSections define a section for ASP.NET Atlas
-->
<configSections>
<sectionGroup name="microsoft.web"
type="Microsoft.Web.Configuration.MicrosoftWebSectionGroup">
<section name="scripts"
type="Microsoft.Web.Configuration.ScriptsSection"/>
<section name="converters"
type="Microsoft.Web.Configuration.ConvertersSection"/>
</sectionGroup>
</configSections>
<!--
atlas.web section defines the script files required for the Atlas
framework when used in the client
-->
<microsoft.web>
<scripts scriptLibraryPath="~/ScriptLibrary/">
</scripts>
<converters>
<add type="Microsoft.Web.Services.Converters.DateTimeConverter"/>
<add type="Microsoft.Web.Services.Converters.DataSetConverter"/>
<add type="Microsoft.Web.Services.Converters.DataRowConverter"/>
<add type="Microsoft.Web.Services.Converters.DataTableConverter"/>
</converters>
</microsoft.web>
<appSettings/>
<connectionStrings/>
<system.web>
<pages>
<controls>
<add namespace="Microsoft.Web" assembly="Microsoft.Web.Atlas"
tagPrefix="atlas"/>
<add namespace="Microsoft.Web.Components"
assembly="Microsoft.Web.Atlas" tagPrefix="atlas"/>
<add namespace="Microsoft.Web.UI"
assembly="Microsoft.Web.Atlas" tagPrefix="atlas"/>
</controls>
</pages>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<compilation debug="false">
<buildProviders>
<add extension=".script"
type="Microsoft.Web.Compilation.ScriptBuildProvider" />
</buildProviders>
</compilation>
<!--
ASMX is mapped to a new handler so that proxy javascripts can also
be served
-->
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx"
type="Microsoft.Web.Services.ScriptHandlerFactory"
validate="false"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule"
type="Microsoft.Web.Services.ScriptModule"/>
</httpModules>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows"/>
<!--
-->
</system.web>
</configuration>
因为以上的Atlas设定,所以网站一开始就必须以Atlas网站型式建立才能使用Atlas控件,否则在普通的ASP.NET网站即便可以拖曳Atlas控件,但因缺乏相关的Atlas Script Library及设定,Atlas网页亦无法执行。
<?xml version="1.0"?>
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
/Windows/Microsoft.Net/Framework/v2.x/Config
-->
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<!--
The configSections define a section for ASP.NET Atlas
-->
<configSections>
<sectionGroup name="microsoft.web"
type="Microsoft.Web.Configuration.MicrosoftWebSectionGroup">
<section name="scripts"
type="Microsoft.Web.Configuration.ScriptsSection"/>
<section name="converters"
type="Microsoft.Web.Configuration.ConvertersSection"/>
</sectionGroup>
</configSections>
<!--
atlas.web section defines the script files required for the Atlas
framework when used in the client
-->
<microsoft.web>
<scripts scriptLibraryPath="~/ScriptLibrary/">
</scripts>
<converters>
<add type="Microsoft.Web.Services.Converters.DateTimeConverter"/>
<add type="Microsoft.Web.Services.Converters.DataSetConverter"/>
<add type="Microsoft.Web.Services.Converters.DataRowConverter"/>
<add type="Microsoft.Web.Services.Converters.DataTableConverter"/>
</converters>
</microsoft.web>
<appSettings/>
<connectionStrings/>
<system.web>
<pages>
<controls>
<add namespace="Microsoft.Web" assembly="Microsoft.Web.Atlas"
tagPrefix="atlas"/>
<add namespace="Microsoft.Web.Components"
assembly="Microsoft.Web.Atlas" tagPrefix="atlas"/>
<add namespace="Microsoft.Web.UI"
assembly="Microsoft.Web.Atlas" tagPrefix="atlas"/>
</controls>
</pages>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<compilation debug="false">
<buildProviders>
<add extension=".script"
type="Microsoft.Web.Compilation.ScriptBuildProvider" />
</buildProviders>
</compilation>
<!--
ASMX is mapped to a new handler so that proxy javascripts can also
be served
-->
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx"
type="Microsoft.Web.Services.ScriptHandlerFactory"
validate="false"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule"
type="Microsoft.Web.Services.ScriptModule"/>
</httpModules>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows"/>
<!--
-->
</system.web>
</configuration>
因为以上的Atlas设定,所以网站一开始就必须以Atlas网站型式建立才能使用Atlas控件,否则在普通的ASP.NET网站即便可以拖曳Atlas控件,但因缺乏相关的Atlas Script Library及设定,Atlas网页亦无法执行。
相关文章推荐
- Silverlight读取webconfig配置文件
- 利用Rsync配置双机主备同步WEB网站文件同步,K哥
- DZ论坛程序的网站的配置文件修改方法
- WebConfig配置文件详解
- IIS7下浏览网站出现503,应用程序池无法启动.事件查看器中出现"Windows 找不到本地配置文件,正在用临时配置文件让您登录。当您注销时,对此配置文件所作的更改将丢失。"
- web.config详解之在文件中配置网站默认页面
- Robots.txt文件如何设置,网站优化之RObots.txt文件的配置
- 解决window2012 IIS8 配置的网站无法下载exe文件的问题
- iis网站,浏览的时候提示:配置文件错误,不允许有子节点。
- 服务器网站报错:由于扩展配置问题无法提供您请求的页面,请添加MIME映射,针对mp4,flv文件类型无法打开。
- 64位系统 IIS7.0配置.net网站时报错:未能加载文件或程序集“XXX”或它的某一个依赖项。试图加载格式不正确的程序。
- 网站部署到IIS7上出现HTTP 错误 500.19(由于权限不足而无法读取配置文件)的问题
- 配置host文件,打开google相关网站
- 发布网站发现编码乱问题,修改Tomact7.0配置文件server.xml
- ASP.NET网站开发中的配置文件
- .Net Core MVC 网站开发(Ninesky) 2.3、项目架构调整(续)-使用配置文件动态注入
- 服务器网站报错:由于扩展配置问题无法提供您请求的页面,请添加MIME映射,针对mp4,flv文件类型无法打开。
- atlas Web.Config 配置文件
- PHP 网站修改默认访问文件的nginx配置
- 网站bin目录下的不可以放配置文件或其他可写文件