我在对项目进行了nuget更新后发现下拉菜单无法正常工作,我猜bootstrap和jquery受到了影响,并且给出了新版本。
当我在Google Chrome浏览器中查看“ developertools”时,我会发现错误
未捕获的错误:语法错误,无法识别的表达式:#jquery-3.3.1.js:1541
请如何解决它:-)
<html lang="en">
<head runat="server">
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title><%: Page.Title %> - Eyeo.se IOT Application and Hardware AB</title>
<asp:PlaceHolder runat="server">
<%: Scripts.Render("~/bundles/modernizr") %>
</asp:PlaceHolder>
<webopt:bundlereference runat="server" path="~/Content/css" />
<link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" />
</head>
<body>
<form runat="server">
<asp:ScriptManager runat="server" >
<Scripts>
<%--To learn more about bundling scripts in ScriptManager see http://go.microsoft.com/fwlink/?LinkID=301884 --%>
<%--Framework Scripts--%>
<asp:ScriptReference Name="MsAjaxBundle" />
<asp:ScriptReference Name="jquery" />
<asp:ScriptReference Name="bootstrap" />
<asp:ScriptReference Name="respond" />
<asp:ScriptReference Name="WebForms.js" Assembly="System.Web" Path="~/Scripts/WebForms/WebForms.js" />
<asp:ScriptReference Name="WebUIValidation.js" Assembly="System.Web" Path="~/Scripts/WebForms/WebUIValidation.js" />
<asp:ScriptReference Name="MenuStandards.js" Assembly="System.Web" Path="~/Scripts/WebForms/MenuStandards.js" />
<asp:ScriptReference Name="GridView.js" Assembly="System.Web" Path="~/Scripts/WebForms/GridView.js" />
<asp:ScriptReference Name="DetailsView.js" Assembly="System.Web" Path="~/Scripts/WebForms/DetailsView.js" />
<asp:ScriptReference Name="TreeView.js" Assembly="System.Web" Path="~/Scripts/WebForms/TreeView.js" />
<asp:ScriptReference Name="WebParts.js" Assembly="System.Web" Path="~/Scripts/WebForms/WebParts.js" />
<asp:ScriptReference Name="Focus.js" Assembly="System.Web" Path="~/Scripts/WebForms/Focus.js" />
<asp:ScriptReference Name="WebFormsBundle" />
<%--Site Scripts--%>
</Scripts>
</asp:ScriptManager>
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" runat="server" href="~/">IOT dashboard portal</a>
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Inställningar<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a runat="server" href="~/sensorer">Sensorer</a></li>
<li><a runat="server" href="~/user">Användare</a></li>
<li><a runat="server" href="~/villkor">Larmvillkor</a></li>
</ul>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Visualisering<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a runat="server" href="~/historychart">Sensordata</a></li>
<li><a runat="server" href="~/tectube_dashboard">Tectube dashboard</a></li>
<li><a runat="server" href="~/processbild">Processbild</a></li>
<li><a runat="server" href="~/processschema">Processschema</a></li>
<li><a runat="server" href="~/mapview">Karta</a></li>
</ul>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Datalogg<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a runat="server" href="~/logg">Larm-logg</a></li>
<li><a runat="server" href="~/indata">Händelse-logg</a></li>
</ul>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Instruktioner<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a runat="server" href="~/manual">Manual</a></li>
<li><a runat="server" href="~/video">Video exempel</a></li>
</ul>
<li><a runat="server" href="~/About">Om</a></li>
<li><a runat="server" href="~/Contact">Kontakt</a></li>
</ul>
<asp:LoginView runat="server" ViewStateMode="Disabled">
<AnonymousTemplate>
<ul class="nav navbar-nav navbar-right">
<%--<li><a runat="server" href="~/Account/Register">Register</a></li>--%>
<li><a runat="server" href="~/Login">Log in</a></li>
</ul>
</AnonymousTemplate>
<LoggedInTemplate>
<ul class="nav navbar-nav navbar-right">
<li><a runat="server" href="~/Account/Manage" title="Manage your account">Hello, <%: Context.User.Identity.GetUserName() %>!</a></li>
<li>
<asp:LoginStatus runat="server" LogoutAction="Redirect" LogoutText="Log off" LogoutPageUrl="~/" OnLoggingOut="Unnamed_LoggingOut" />
</li>
</ul>
</LoggedInTemplate>
</asp:LoginView>
</div>
</div>
</div>
<div class="container body-content">
<asp:ContentPlaceHolder ID="MainContent" runat="server">
<asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
</asp:ContentPlaceHolder>
<asp:ContentPlaceHolder ID="ContentPlaceHolder2" runat="server">
</asp:ContentPlaceHolder>
</asp:ContentPlaceHolder>
<hr />
<footer>
<p>© 2018 - Eyeo.se / IOT application and hardware AB. Tel 0500-6000 22 </p>
</footer>
</div>
</form>
</body>
</html>