0

When I download project in https://www.codeigniter.com/user_guide/installation/downloads.html

CodeIgniter v2.2.0

When I run http://localhost/qldv, I get result as welcome page of codeigniter, but when I register in routes.php with route

$route['admin/welcome'] = 'welcome';

When I go to web with link: http://localhost/qldv/admin/welcome

I don't get welcome page. Result is

Object not found!

Please help me. Thanks

Racil Hilan
  • 24,690
  • 13
  • 50
  • 55
jonny
  • 165
  • 3
  • 13

3 Answers3

0

If you don't disable having to put index.php in the URL (using an htaccess file), this route won't work. This would: http://localhost/qldv/index.php/admin/welcome

To disable index.php in the url look at this question: CodeIgniter removing index.php from url

Community
  • 1
  • 1
which1ispink
  • 3,018
  • 3
  • 14
  • 24
-1

Put this code in your Welcome Controller.

public function admin()
{
    $this->load->view('welcome_message');
}
Rexie Galban
  • 88
  • 1
  • 1
  • 6
-1

Put this code in your Welcome Controller.public function admin() { $this->load->view('welcome_message'); }