ChronoFish ChronoFish - 4 months ago 21
CSS Question

What are possible reasons for bonfire Assets::add_module_css to not include file?

I have a primary controller located in

secure/application/modules/gps/controllers
that has a constructor that looks like this:

public function __construct()
{
parent::__construct();
$this->load->model('gps_model');
Assets::add_module_js('gps', 'gps.js');
Assets::add_module_css('gps','gps.css');
if($this->input->get('clear') != false){
$this->session->sess_destroy();
}
}


My CSS file that I am trying to include is located in the folder
secure/application/modules/gps/assets/css
. The code executes fine without warning, but the CSS file does not get included for any methods. Is there a configuration setting the may override the assets directory, or is there some other reason it's not being found/added? (The JS file is not being added either. The bonfire base CSS files (screen.css) IS getting loaded fine.

Answer

We found the solution to our particular problem.

The assets/cache directory did not exist. Once the server could write (it must exist and be writeable!) to the [document_root]/bonfire/public/assets/cache directory all was good.

Comments