• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
using base_url in errors/error_404.php

#4
[eluser]vrencianz[/eluser]
Well, I show you what I did to test your issue (fresh codeigniter installation)

1) modified error_404.php as follows:

Code:
<body>
<div id="container">
  <h1>&lt;?php echo $heading; ?&gt;</h1>
  &lt;?php echo $message; ?&gt;
</div>

&lt;?php
$CI =& get_instance();
$CI->load->helper('url');
echo base_url();  
?&gt;


2) created a test controller (test.php)

Code:
class Test extends CI_Controller
{
function index()
{
  show_404('test');
}
}

3) accessed
Code:
http://localhost/codeigniter/test
(my base url is set to
Code:
http://localhost/codeigniter/)

and the path is displayed.

Maybe you must check your base url in config.php.


Messages In This Thread
using base_url in errors/error_404.php - by El Forum - 05-08-2012, 11:02 PM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 12:57 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 01:04 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 01:15 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 01:24 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 01:54 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 01:59 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 02:15 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 10:06 AM
using base_url in errors/error_404.php - by El Forum - 05-09-2012, 04:37 PM
using base_url in errors/error_404.php - by El Forum - 05-06-2013, 08:43 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.