我想使用IE条件注释来加载基于IE版本的Angular脚本。但条件注释不起作用,因为角度未定义,它会抛出错误?谁能帮我这个? IE条件注释在<asp:content>
标记内不起作用?
<asp:Content ID="Content2" ContentPlaceHolderID="ScriptSection" runat="server">
<!--[if lt IE 9]>
<script src='<%= Page.ResolveClientUrl("~/Scripts/angular-1.2.16.min.js")%>' type="text/javascript"></script>
<![endif]-->
<!--[if gte IE 9]>
<script src='<%= Page.ResolveClientUrl("~/Scripts/angular.min.js")%>' type="text/javascript"></script>
<![endif]-->
</asp:Content>
答案 0 :(得分:1)
<![if IE]>
<script src='<%= Page.ResolveClientUrl("~/Scripts/angular-1.2.16.min.js")%>' type="text/javascript"></script>
<![endif]>
<![if IE]>
<script src='<%= Page.ResolveClientUrl("~/Scripts/angular.min.js")%>' type="text/javascript"></script>
<![endif]>