I use CodeIgniter Template and CodeIgniter PHP framework. I don't know how works metadata in this library (template). I try to add style.css to my layout. In User Guide I've found info:
**prepend_metadata()**
Add a line to the start of the $template['metadata'] string.
Parameters
$line - string REQUIRED - Metadata line.
Usage
$this->template->prepend_metadata('<script src="/js/jquery.js"></script>');
In my layout file I have:
<head>
<title>TITLE</title>
<?=$template['metadata']?>
</head>
In Controller file:
$this->template
->prepend_metadata('<link rel="stylesheet" href="css/style.css" type="text/css" media="all" />')
->set_layout('index');
It's look like good, but don't work at all.
Style.css is in views/css/style.css and layout file (index.php) is in views/css/layout/index.php.
Thanks for help!
base_url()
+'/directory/path/to/css'
orbase_url('directory/path/to/css')