Reputation: 1593
I am new to codeIgniter and Linux as well. When I tried to run http://localhost/CodeIgniter/hello/first_page
it shows 404 Error: Page not found
. My Controller class :
/*hello.php*/
class Hello extends CI_Controller
{
function __construct() {
parent::__construct();
}
function first_page()
{
$this->load->view('first_view');
}
}
And my first_view.php
is :
<html>
<head>
<title>First CI Page</title>
</head>
<body>
Hi Folks !
</body>
<?php
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
?>
</html>
NB: http://localhost/CodeIgniter
shows the welcome message.And all files are executable(777)
Upvotes: 0
Views: 1369
Reputation: 2703
Try this url.. You'll get it
http://localhost/CodeIgniter/index.php/hello/first_page
You have to include index.php
Upvotes: 3