Reputation: 8621
I'm working with CodeIgniter and I'm trying to use some stylesheets.
In my autoload.php I have $autoload['helper'] = array('html','url');
and on my view page I have
<link rel="stylesheet" src="<?php echo base_url('assets/css/bootstrap.css')?>"/>
<link rel="stylesheet" src="<?php echo base_url('assets/css/bootstrap-theme.css')?>"/>
<script src="<?php echo base_url('assets/js/jquery-2.2.4.js')?>"></script>
<script src="<?php echo base_url('assets/js/bootstrap.js')?>"></script>
I'm attempting to use stylesheets from Bootstrap, to make a nav bar appear.
Here is my navbar:
<nav class="navbar navbar-default">
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="#">
<img alt="Brand" src="...">
</a>
</div>
</div>
</nav>
The problem is the CSS doesn't seem to be working at all.
When I look at the page source, the proper links are included to the stylesheets in my <head></head>
tags, but I get no change on the page itself.
Upvotes: 1
Views: 477
Reputation: 9872
src
should be href
.read more
don't use src
for link tag
<link rel="stylesheet" href="<?php echo base_url('assets/css/bootstrap.css')?>"/>
Upvotes: 4