我是skel.js框架的新手,并且遇到了一些问题。
我从HTML5UP.net(零零主题)下载了一个模板,并且已经为我的网站进行了全部修改,但是CSS在我的无侧边栏和左侧边栏页面上无法正确显示。
我包含以下链接(与它们的模板相同):
<link href="http://fonts.googleapis.com/css?family=Open+Sans:400,300,700,800" rel="stylesheet" type="text/css" />
<script src="http://www.**********.com/js/jquery.min.js"></script>
<script src="http://www.**********.com/js/jquery.dropotron.js"></script>
<script src="http://www.**********.com/js/config.js"></script>
<script src="http://www.**********.com/js/skel.min.js"></script>
<script src="http://www.**********.com/js/skel-panels.min.js"></script>
<noscript>
<link rel="stylesheet" href="http://www.*********.com/css/skel-noscript.css" />
<link rel="stylesheet" href="http://www.*********.com/css/style.css" />
<link rel="stylesheet" href="http://www.*********.com/css/style-desktop.css" />
</noscript>
如果我绕过noscript,则该网页会按原样显示,但会丢失所有可移动和可流动的功能。
任何想法将不胜感激!
插件:如果我将页面移动到根目录并更新链接,则CSS可以工作,但在其子目录中,仅基本布局可以工作。
<?php
define(currentDIR,'../');
include (currentDIR.'includes/_functions.php');
?>
<html>
<head>
<?php include(currentDIR.'includes/_metalinks.php'); ?> //This is where the code above is stored
</head>
在Django上使用HTML5up模板时,我也遇到了这个问题。如果您对静态文件使用其他目录配置,则必须在init.js或config.js文件中指定此配置(确切的文件取决于您使用的模板以及其最近更新的时间)。对我来说,我必须在init.js文件中修改以下skelJS前缀:
var helios_settings = {
// other settings here
skelJS: {prefix: '/static/css/style',
// other settings here
}
基本上,无论您在哪里拥有静态文件,此目录前缀都必须匹配。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句