当前位置: 首页>>代码示例>>PHP>>正文


PHP theme::register_script方法代码示例

本文整理汇总了PHP中theme::register_script方法的典型用法代码示例。如果您正苦于以下问题:PHP theme::register_script方法的具体用法?PHP theme::register_script怎么用?PHP theme::register_script使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在theme的用法示例。


在下文中一共展示了theme::register_script方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

// Theme Autoloader
require_once __DIR__ . '/includes/autoload.php';
// Alias to our custom theme class
// Alternatively, you could just extend \projectcleverweb\lastautoindex\theme
class theme extends \projectcleverweb\lastautoindex\themes\default_theme\main
{
}
// Run our custom init
theme::init();
// Register all scripts & styles (you need to queue them if you want to use them on a page)
// Styles - theme::register_style($id, $url [, $options = array('order' => 1000)])
theme::register_style('font-awesome', theme::$styles_uri . '/font-awesome.min.css', array('order' => 600));
theme::register_style('webicons', theme::$styles_uri . '/webicons.min.css', array('order' => 700));
theme::register_style('semantic', theme::$styles_uri . '/semantic-ui/semantic.min.css', array('order' => 800));
theme::register_style('highlight-js', theme::$styles_uri . '/highlight.js/github.min.css', array('order' => 900));
theme::register_style('readme', theme::$styles_uri . '/readme.css');
theme::register_style('main', theme::$styles_uri . '/main.css', array('order' => 1500));
// Scripts - theme::register_script($id, $url [, $options = array('order' => 1000)])
theme::register_script('jquery', theme::$scripts_uri . '/jquery-2.1.3.min.js', array('order' => 500));
theme::register_script('modernizr', theme::$scripts_uri . '/modernizr-2.8.3.min.js', array('order' => 600));
theme::register_script('moustrap', theme::$scripts_uri . '/mousetrap.min.js', array('order' => 700));
theme::register_script('highlight-js', theme::$scripts_uri . '/highlight.pack.min.js', array('order' => 800));
theme::register_script('semantic', theme::$scripts_uri . '/semantic.min.js', array('order' => 900));
theme::register_script('tablesort', theme::$scripts_uri . '/jquery.tablesort.min.js');
theme::register_script('main', theme::$scripts_uri . '/main.js', array('order' => 1500));
// Add special cases for when trying to login or install
if (isset($_GET['login']) && theme::$config['allow_login']) {
    theme::use_part('login', 'template', 'index');
} elseif (isset($_GET['install']) && defined('LAI_INSTALLED') && LAI_INSTALLED === FALSE) {
    theme::use_part('install', 'template', 'index');
}
开发者ID:rezgui,项目名称:LastAutoIndex,代码行数:31,代码来源:config.php


注:本文中的theme::register_script方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。