Fatal error Call to undefined function base url in C wamp www Test-CI application views layout php on line 5

0 votes

I am getting this error when I tried to set up CodeIgnitor. 

Fatal error: Call to undefined function base_url() in
  1. C:\wamp\www\Test-CI\application\views\layout.php on line 5
    
  2. {main}( ) IN ..\index.php:0 require_once('C:\wamp\www\Test-CI\system\core\CodeIgniter.php' ) IN ..\index.php:202
  3. call_user_func_array ( ) IN ..\CodeIgniter.php:359
  4. Home->index( ) IN ..\CodeIgniter.php:0
  5. CI_Loader->view( ) IN ..\home.php:17
  6. CI_Loader->_ci_load( ) IN ..\Loader.php:419
  7. include('C:\wamp\www\Test-CI\application\views\layout.php' ) IN ..\Loader.php:833

My code :

 <html>
    <head>
        <meta http-equiv="Content-type" content="text/html; charset=utf-8">
        <title>Galleriffic | Custom layout with external controls</title>
        <link rel="stylesheet" href="<?php base_url(); ?>/assets/css/basic.css" type="text/css" />
        <link rel="stylesheet" href="<?php base_url(); ?>/assets/css/galleriffic-5.css" type="text/css" />
        
        <!-- <link rel="stylesheet" href="<?php base_url(); ?>/assets/css/white.css" type="text/css" /> -->
        <link rel="stylesheet" href="<?php base_url(); ?>/assets/css/black.css" type="text/css" />
        
        <script type="text/javascript" src="<?php base_url(); ?>/assets/js/jquery-1.3.2.js"></script>
        <script type="text/javascript" src="<?php base_url(); ?>/assets/js/jquery.history.js"></script>
        <script type="text/javascript" src="<?php base_url(); ?>/assets/js/jquery.galleriffic.js"></script>
        <script type="text/javascript" src="<?php base_url(); ?>/assets/js/jquery.opacityrollover.js"></script>
        <!-- We only want the thunbnails to display when javascript is disabled -->
        <script type="text/javascript">
            document.write('<style>.noscript { display: none; }</style>');
        </script>
    </head>

Can someone explain to me why this error occurred? and how can I solve this?

 

May 5, 2022 in PHP by Kichu
• 19,050 points
1,739 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In PHP

0 votes
1 answer

Fatal error: Call to undefined function ImageCreate() in /home/t1g01/phplot.php on line 248

Hello @kartik, Your server most like does not ...READ MORE

answered Nov 18, 2020 in PHP by Niroj
• 82,880 points
5,818 views
0 votes
1 answer
0 votes
1 answer

Fatal error: Call to undefined function imap_open() in PHP

Hello @kartik, In Ubuntu for install imap use sudo ...READ MORE

answered Oct 29, 2020 in PHP by Niroj
• 82,880 points
5,082 views
0 votes
1 answer

Error:Undefined index: barangay in C:\xampp\htdocs\TextBlast\homepage\insert.php on line 22

Hello @ Regina, First checks whether a variable is ...READ MORE

answered Aug 14, 2020 in PHP by Niroj
• 82,880 points
5,389 views
–1 vote
1 answer
0 votes
1 answer
0 votes
1 answer

CodeIgniter removing index.php from url

To solve your doubt, use the following ...READ MORE

answered Feb 23, 2022 in PHP by Aditya
• 7,680 points
896 views
0 votes
0 answers

php error: The Encrypt library requires the Mcrypt extension in codeigniter

I have a  login and sign-up form and ...READ MORE

Jun 20, 2022 in PHP by Kithuzzz
• 38,010 points
2,600 views
0 votes
0 answers
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP