【发布时间】:2012-06-25 18:29:18
【问题描述】:
我下载了 jquery ui 主题的 redmond 主题。将 redmond 下的所有内容复制到 \content\themes,将 jquery-ui-1.8.21.custom.min.js 复制到 \scripts,将 jquery 更新到 jquery-1.7.2.js 并将以下内容添加到 _Layout.cshtml。 但是,用户界面似乎没有改变。
<meta charset="utf-8" />
<title>@ViewBag.Title - My ASP.NET MVC Application</title>
<link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" />
<link href="@System.Web.Optimization.BundleTable.Bundles.ResolveBundleUrl("~/Content/css")" rel="stylesheet" type="text/css" />
<link href="@Url.Content("~/Content/themes/redmond/jquery-ui-1.8.21.custom.css")" rel="stylesheet" type="text/css" />
<script src="@Url.Content("~/Scripts/jquery-1.7.2.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-ui-1.8.21.custom.min.js")" type="text/javascript"></script>
<meta name="viewport" content="width=device-width" />
Here is the structure of the Content folder
Content
Themes
base
redmond
images
jquery-ui-1.8.21.custom.css
Site.css
Scripts
jquery-1.7.2.min.js
jquery-ui-1.8.21.custom.min.js
【问题讨论】:
-
看起来不错。查看源代码并单击样式表的链接,看看它是否是 404。
-
我在浏览器中粘贴了css文件和js文件的url,都是有效的。
-
jquery-ui-1.8.21.custom.css里面的图片Urls是否指向正确的地方? -
我相信图片网址指向了正确的位置。我已经更新了我的问题。查看内容文件夹结构。
-
你的浏览器缓存了吗? (尝试几次 Ctrl + F5 清除缓存。)
标签: jquery asp.net user-interface themes asp.net-mvc-4