CodeIgniter Forums
salam kenal - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: General (https://forum.codeigniter.com/forumdisplay.php?fid=1)
+--- Forum: Regional User Groups (https://forum.codeigniter.com/forumdisplay.php?fid=25)
+--- Thread: salam kenal (/showthread.php?tid=63102)



salam kenal - black_end - 09-27-2015

ane baru belajar nieh

anekan baca ebook
terus di suruh
bikin
<?php
class Hello extends controller
{
function index()
{
$this->load->view('helloview');
}
}?
>

tapi kok malah muncul


Fatal error: Class 'controller' not found in C:\xampp\htdocs\ci\application\controllers\hello.php on line 3


RE: salam kenal - _this - 09-28-2015

Hello black_end,

First, please use english when you post to this forum, if not, you will hardly get an answer...

I think I got what you mean, and it's a simple mistake with caps : you're trying to extend the Controller CI's Core Class to create your own controller, but there's a little mistake in your extends.

PHP Code:
class Hello extends Controller 

CodeIgniter classes are case sensitive so it will not work if you don't follow framework's naming conventions.

Regards,

$this.