mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-18 18:46:17 +00:00
Removing APP_PATH it is always the same as APP.
Fixing a typo in index.php.
This commit is contained in:
parent
20e9015f80
commit
6e2870c706
6 changed files with 6 additions and 16 deletions
|
@ -37,10 +37,4 @@
|
|||
define('CAKE_CORE_INCLUDE_PATH', ROOT . DS . 'lib');
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the include path or define app and core path
|
||||
*/
|
||||
define('APP_PATH', ROOT . DS . APP_DIR . DS);
|
||||
define('CORE_PATH', CAKE_CORE_INCLUDE_PATH . DS);
|
||||
|
||||
require APP_DIR . DS . WEBROOT_DIR . DS . 'index.php';
|
||||
|
|
|
@ -45,7 +45,7 @@ class CommandListShell extends Shell {
|
|||
if (empty($this->params['xml'])) {
|
||||
$this->out(__d('cake_console', "<info>Current Paths:</info>"), 2);
|
||||
$this->out(" -app: ". APP_DIR);
|
||||
$this->out(" -working: " . rtrim(APP_PATH, DS));
|
||||
$this->out(" -working: " . rtrim(APP, DS));
|
||||
$this->out(" -root: " . rtrim(ROOT, DS));
|
||||
$this->out(" -core: " . rtrim(CORE_PATH, DS));
|
||||
$this->out("");
|
||||
|
|
|
@ -50,7 +50,7 @@ class ProjectTask extends Shell {
|
|||
|
||||
while (!$project) {
|
||||
$prompt = __d('cake_console', "What is the path to the project you want to bake?");
|
||||
$project = $this->in($prompt, null, APP_PATH . 'myapp');
|
||||
$project = $this->in($prompt, null, APP . 'myapp');
|
||||
}
|
||||
|
||||
if ($project && !Folder::isAbsolute($project) && isset($_SERVER['PWD'])) {
|
||||
|
|
|
@ -206,7 +206,7 @@ class Shell extends Object {
|
|||
$this->out(__d('cake_console', '<info>Welcome to CakePHP %s Console</info>', 'v' . Configure::version()));
|
||||
$this->hr();
|
||||
$this->out(__d('cake_console', 'App : %s', APP_DIR));
|
||||
$this->out(__d('cake_console', 'Path: %s', APP_PATH));
|
||||
$this->out(__d('cake_console', 'Path: %s', APP));
|
||||
$this->hr();
|
||||
}
|
||||
|
||||
|
|
|
@ -122,15 +122,15 @@ class ShellDispatcher {
|
|||
private function __bootstrap() {
|
||||
define('ROOT', $this->params['root']);
|
||||
define('APP_DIR', $this->params['app']);
|
||||
define('APP_PATH', $this->params['working'] . DS);
|
||||
define('WWW_ROOT', APP_PATH . $this->params['webroot'] . DS);
|
||||
define('APP', $this->params['working'] . DS);
|
||||
define('WWW_ROOT', APP . $this->params['webroot'] . DS);
|
||||
if (!is_dir(ROOT . DS . APP_DIR . DS . 'tmp')) {
|
||||
define('TMP', CAKE_CORE_INCLUDE_PATH . DS . 'Cake' . DS . 'Console' . DS . 'Templates' . DS . 'skel' . DS . 'tmp' . DS);
|
||||
}
|
||||
$boot = file_exists(ROOT . DS . APP_DIR . DS . 'Config' . DS . 'bootstrap.php');
|
||||
require CORE_PATH . 'Cake' . DS . 'bootstrap.php';
|
||||
|
||||
if (!file_exists(APP_PATH . 'Config' . DS . 'core.php')) {
|
||||
if (!file_exists(APP . 'Config' . DS . 'core.php')) {
|
||||
include_once CAKE_CORE_INCLUDE_PATH . DS . 'Cake' . DS . 'Console' . DS . 'Templates' . DS . 'skel' . DS . 'Config' . DS . 'core.php';
|
||||
App::build();
|
||||
}
|
||||
|
|
|
@ -31,10 +31,6 @@ if (!defined('CORE_PATH')) {
|
|||
define('CORE_PATH', CAKE_CORE_INCLUDE_PATH . DS);
|
||||
}
|
||||
|
||||
if (!defined('APP_PATH')) {
|
||||
define('APP_PATH', ROOT . DS . APP_DIR . DS);
|
||||
}
|
||||
|
||||
if (!defined('WEBROOT_DIR')) {
|
||||
define('WEBROOT_DIR', 'webroot');
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue