• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rest Controller Error, Not Sure How To Troubleshoot

#1
Hello,

Of course at this point, I created an account, searched through the forum for some possible insight, but I tried implementing Chrisk Acer Guis CodeIgniter Rest Server {https://github.com/chriskacerguis/codeigniter-restserver} and I encountered a problem when trying to access a particular controller.

Error::

Fatal error: Class 'REST_Controller' not found in /var/www/html/my_website_here/application/controllers/admin/Pages.php on line 5

Pages Class::


Code:
<?php defined('BASEPATH') OR exit('NO direct script access allowed');

require APPPATH.'/libraries/REST_Controller.php';

class Pages extends REST_Controller {

   function __construct() {

      parent::__construct();
   }

   function page_get() {

      // Test Only
   }

}



I tried Google and there's no real steps to trouble shoot here. I'm not sure if there's a conflict somewhere, I'm using CodeIgniter 3.


Attached Files Thumbnail(s)
   
Reply

#2
Try:
PHP Code:
require APPPATH.'libraries/REST_Controller.php'
Reply

#3
It should be require_once the docs say.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply

#4
Troubleshooting: Take the source before this commit: https://github.com/chriskacerguis/codeig...3a2a1a41a3
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


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