Your css file should be in publicly approachable directory.
Application directory (application
or APPPATH
) is not publicly reachable.
So your CSS file should be somewhere next to index.php
file of your application.
It is common to have assets/css
path started in your website root:
-application
-system
-assets
--css
---vehicle.css
-index.php
-.htaccess
And if you make your web application code that uses CSS files dinamicaly regarding of route used, you can resolve it by adding more related subfolders:
-application
-system
-assets
--css
---vehicle
----style.css
-index.php
-.htaccess
This way, after url
helper is loaded, you could reach css link with:
<?php echo base_url('assets/css/vehicle/style.css');?>
Eventualy you should include assets
location in .htaccess
file enabling Apache server to allow reading of it.