I am using Composer with CodeIgniter in my vagrant. My development environment is CentOS 6.5, PHP 5.6. I've loaded my other package from github through composer.json
and in my development environment everything working fine. When I loaded the full folder in my DigitalOcean VPS and try to run the application,
I got this Fatel error.
Fatal error: Class 'AppioLab\LRPC\Lrpc' not found in /var/www/html/personal/demo/lstoxero/public_html/application/controllers/mytest.php on line 43
Line 43 is where I am trying to create an instance of Class I've loaded through composer and autoload.php
This is my folder structure
This is my Test Controller
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
use AppioLab\LRPC\Lrpc;
error_reporting(E_ALL);
ini_set('display_errors', 1);
class MyTest extends CI_Controller {
public function test(){
echo "Cron Test<br>";
$lrpc = new Lrpc(); // this is line 43 in my code.
echo "lrpc loadedt<br>";
}
}
When I try to access this test function with url http://mydemosite.com/MyTest/test
i get the error I mention above. What I am doing wrong and why its running in vagrant but not in live which is also CentOS 6.5?
Your answer may help me solve it quickly. Thanks in Advance.