I have a ZF2 application that is functional on several machines. All running Zend Server. It has been very difficult to hunt down the problem so please ask questions to help get closer to the issue.
The Machines running the application are :
- Zend Server on Osx El Capitan.
- Zend Server on Centos 7 using virtual box
- Zend Server on Centos 6.
The machine that shows the problem is running:
- Zend Server on Centos 6 using Virtual box.
A use statement like this
use Zend\Db\Sql\Ddl\Column\DateTime;
Would throw an error on the problematic machine but not on the working machines. That is because the actual class name is Datetime
and not DateTime
. So changing the T
to t
gets rid of the error.
Is there certain php configuration I am missing and that is why i have this error? or is it zend server or operating system issue?
php -v PHP 7.0.11
zend server version 9.0.1
Another error I get :
While attempting to create apiv1modulenamecontroller(alias: Api\V1\ModuleName\Controller) an invalid factory was registered for this instance type.
note the lowerCase in apiv1modulenamecontroller
This happens by design. It is just the way the Linux operating system is designed. As a rule of thumb, it is recommended to always create your code for case-sensitive file systems so that your code is ready if ever you deploy your code to a server that follows this strictly.