为什么此注释导致分析器错误?

时间:2013-06-06 23:06:28

标签: asp.net google-chrome parse-error ysod

当尝试在asp.net应用程序中打开特定页面时,我得到了一个YSOD:

Server Error in '/CommonLoon' Application.

Parser Error

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. 

Parser Error Message: Only Content controls are allowed directly in a content page that contains Content controls.

Source Error: 


Line 9:  </asp:Content>
Line 10: 
Line 11: <!-- Might want to replace this old .css with a newer version, such as 1.10.2: http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css -->
Line 12: <asp:Content ID="indexStyles" ContentPlaceHolderID="MainHead" runat="server">
Line 13:     <link type="text/css" href="/<%= System.Configuration.ConfigurationManager.AppSettings["ThisApp"] %>/Content/jquery-ui-1.8.16.custom.css"

Source File: /CommonLoon/Views/Home/Index.aspx    Line: 11 

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.272

首先,为什么注释掉的一行有问题?

其次......其次是第二个:那个文件没有(或不再)有评论;相反,它现在就在那条线上:

<!-- 5/6/2013: Replace 1.8.16 with a newer css, such as http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css? The "custom" part of the name of the file makes me hesitate to make a change, though... -->

该文件的旧版本来自哪里?短语“可能想要”并没有出现在解决方案的任何地方...... ???

更新

陌生人;我刚刚取消注释了一些迄今为止已经注释掉jQjuery以测试旧功能,并且没有注意到有一条注释应该阻止代码编译,即:

$("#BeginDate").datepicker( try this as a anytime date component

......然而它已编译并运行!天堂到Murgatroid!怎么了???!?

0 个答案:

没有答案