I have a project in my localhost that works impeccably, I uploaded the project to a cPanel server in Hostgator, I updated php to its version 7.0 so that everything works ok, I uploaded it to a folder and create a subdomain that points to the folder public
But when I enter the subdomain directly I get the following error:
Zend \ Mvc \ Controller \ ControllerManager :: createFromInvokable: failed retrieving "appscontrollerindex (alias: Apps \ Controller \ Index)" via invokable class "Apps \ Controller \ IndexController"; class does not exist
Then I try to go to the authentication driver and it throws me the following error:
Fatal error: Uncaught Error: Class 'Users\Model\Users' not found ...
- UPDATE 1 ---
In the Authentication module, so I define the controller in the file module.config.php
:
'controllers' => array(
'invokables' => array(
'Authentication\Controller\Index' => 'Authentication\Controller\IndexController'
),
),
And in the file IndexController
of the Authentication module, this line includes the Users class:
use Users\Model\Users;
And then within an action I call it like this:
$this->dbAdapter =$this->getServiceLocator()->get('Zend\Db\Adapter');
$users = new Users($this->dbAdapter);
- UPDATE 2 ---
I was doing everything possible because it worked, I contacted Hostagtor technical support and they told me that reseller and web plans are not compatible with ZF2 and that's why they did not work. So I'm looking for another server that even has a instructional for to install ZF2