Unable to get css on page |
Hi
I am trying to get css called in but I am getting errors . what should I do . pfa!! Thanks
You probably need to link to your files using base_url() which you can read about here: http://www.codeigniter.com/user_guide/he...l#base_url
So in the head you would have for style sheets something like: PHP Code: <link href="<?php echo base_url('assets/bootstrap/css/bootstrap.min.css'); ?>" rel="stylesheet"> and for your footer js links something like: PHP Code: <script src="<?php echo base_url('assets/bootstrap/js/bootstrap.min.js'); ?>"></script> Hope that helps, Best wishes, Paul.
(09-28-2015, 12:35 PM)PaulD Wrote: You probably need to link to your files using base_url() which you can read about here: http://www.codeigniter.com/user_guide/he...l#base_url Thanks PaulD its working fine now !!
You could also just use an absolute url, starting with a / to start from site root:
<link href="/assets/bootstrap/css/bootstrap.min.css" rel="stylesheet">
|
Welcome Guest, Not a member yet? Register Sign In |