我的资源文件夹的文件夹结构如下所示
project_root_folder - >资产 - > css - > {stylesheet.css,sample.css,something.css}
project_root_folder - >资产 - > js - > {jquery.min.js,sample.js,something.js}
project_root_folder - >资产 - >高速缓存
project_root_folder - > system - >插件 - > csstidy
project_root_folder - > system - >插件 - > jsmin.php
application/config/assetlibpro.php
$config['alp_csstidy_basepath'] = "/system/plugins/csstidy";
$config['alp_jsmin'] = "/system/plugins/jsmin.php";
$config['alp_asset_dir'] = 'assets/';//TRAILING SLASH!
$config['alp_cache_dir_css'] = 'assets/cache/';//TRAILING SLASH!
$config['alp_cache_dir_js'] = 'assets/cache/';//TRAILING SLASH!
在我的config/autoload.php
$autoload['libraries'] = array('assetlibpro');
在我的控制器中,
$this->assetlibpro->add_css('stylesheet.css'); // Stylesheet file
$this->assetlibpro->add_js('jquery-2.1.0.min.js'); // JavaScript file
$data['common_css']=$this->assetlibpro->output('css'); // Store the CSS in the variable
$data['homepage_js']=$this->assetlibpro->output('js'); // Store the JS in the variable
$this->load->view('main-homepage', $data); // Load homepage view
在main-homepage.php中,
echo $common_css;
echo $homepage_js;
但页面不会抛出任何错误或输出CSS和JS。我做错了什么?