Link CSS and Javascript File in Codeigniter
Paste in view
<link rel="stylesheet" href="<?php echo base_url(); ?>assets/css/style.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="<?php echo base_url(); ?>assets/js/custom.js" ></script>
Definite base URL in config.php file (D:\wamp\www\codelearning\application\config)
$config['base_url'] = 'http://localhost/codelearning/';
Comments
Post a Comment