diff --git a/app/webroot/index.php b/app/webroot/index.php index 77b9db786dd..3c5e7158981 100644 --- a/app/webroot/index.php +++ b/app/webroot/index.php @@ -75,6 +75,6 @@ return; } - require LIBS . 'Routing' . DS .'Dispatcher.php'; + App::uses('Dispatcher', 'Routing'); $Dispatcher = new Dispatcher(); $Dispatcher->dispatch(new CakeRequest()); diff --git a/lib/Cake/Console/Command/Task/ProjectTask.php b/lib/Cake/Console/Command/Task/ProjectTask.php index addf35a0083..19bd4ac01e1 100644 --- a/lib/Cake/Console/Command/Task/ProjectTask.php +++ b/lib/Cake/Console/Command/Task/ProjectTask.php @@ -52,14 +52,6 @@ public function execute() { $project = $_SERVER['PWD'] . DS . $project; } - if (empty($this->params['skel'])) { - $core = App::core('Console'); - $skelPath = dirname($core[0]) . DS . 'templates' . DS . 'skel'; - if (is_dir($skelPath) === true) { - $this->params['skel'] = $skelPath; - } - } - while (!$project) { $prompt = __("What is the full path for this app including the app directory name?\n Example:"); $default = APP_PATH . 'myapp'; @@ -387,6 +379,7 @@ public function getOptionParser() { ))->addOption('empty', array( 'help' => __('Create empty files in each of the directories. Good if you are using git') ))->addOption('skel', array( + 'default' => current(App::core('Console')) . DS . 'templates' . DS . 'skel', 'help' => __('The directory layout to use for the new application skeleton. Defaults to cake/console/templates/skel of CakePHP used to create the project.') )); } diff --git a/lib/Cake/Console/templates/default/views/home.ctp b/lib/Cake/Console/templates/default/views/home.ctp index 22217b2fb8d..b707e5eb399 100644 --- a/lib/Cake/Console/templates/default/views/home.ctp +++ b/lib/Cake/Console/templates/default/views/home.ctp @@ -2,7 +2,7 @@ $output = "

Sweet, \"" . Inflector::humanize($app) . "\" got Baked by CakePHP!

\n"; $output .=" 0): Debugger::checkSecurityKeys(); endif; @@ -52,27 +52,38 @@ endif; ?>

getDataSource('default'); ?>

+ isConnected()): + echo ''; + echo __('Cake is able to connect to the database.'); + echo ''; + else: + echo ''; + echo __('Cake is NOT able to connect to the database.'); + echo ''; + endif; + ?> +

+ isConnected()): - echo ''; - echo __('Cake is able to connect to the database.'); - echo ''; - else: - echo ''; - echo __('Cake is NOT able to connect to the database.'); - echo ''; - endif; -?> -

\n"; -$output .= "\n"; + App::uses('Validation', 'Utility'); + if (!Validation::alphaNumeric('cakephp')) { + echo '

'; + __('PCRE has not been compiled with Unicode support.'); + echo '
'; + __('Recompile PCRE with Unicode support by adding --enable-unicode-properties when configuring'); + echo '

'; + } +?>\n"; $output .= "

\n"; $output .= "

\n"; $output .= "dispatch(new CakeRequest()); diff --git a/lib/Cake/View/pages/home.ctp b/lib/Cake/View/pages/home.ctp index 4c51432de56..96aa8dfadb2 100644 --- a/lib/Cake/View/pages/home.ctp +++ b/lib/Cake/View/pages/home.ctp @@ -18,7 +18,7 @@ if (Configure::read('debug') == 0): throw new NotFoundException(); endif; -App::import('Core', 'Debugger'); +App::uses('Debugger', 'Utility'); ?>

@@ -71,16 +71,6 @@ endif; endif; ?>

-'; - __('PCRE has not been compiled with Unicode support.'); - echo '
'; - __('Recompile PCRE with Unicode support by adding --enable-unicode-properties when configuring'); - echo '

'; - } -?>

+'; + __('PCRE has not been compiled with Unicode support.'); + echo '
'; + __('Recompile PCRE with Unicode support by adding --enable-unicode-properties when configuring'); + echo '

'; + } +?>