Question

I should have access to CakePHP constants in an external application on the same server.

What is best practise to include parts of a CakePHP application, to access them?

already tried to include bootstrap.php:

Fatal error: Class 'Cache' not found in /Users/Patrick/Sites/project/Config/bootstrap.php on line 27

line 27 in bootstrap.php:

Cache::config('default', array('engine' => 'File'));

Was it helpful?

Solution

Best practice is to make a plugin for it. That creates a separation of concerns. Just including parts from Cake into another piece of software will create a mess likely. Think about what happens when CakePHP Framework get's to a new version. After a while it is totally unclear what is integrated and what not while you have to check only your plugin(s) to see the integration in the other case.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top