Wednesday, May 27, 2009

Re: Moving a webapp from Windows to Linux

Hello Brian

Here's how I have defined CORE_PATH....

if (!defined('CAKE_CORE_INCLUDE_PATH')) {
//define ('CAKE_CORE_INCLUDE_PATH', FULL PATH TO DIRECTORY WHERE
CAKE CORE IS INSTALLED');
//You should also use the DS define to seperate your directories
define('CAKE_CORE_INCLUDE_PATH',
DS.'webapp'.DS.'code'.DS.'app_name'.DS.'cake');
}

if (!defined('CORE_PATH')) {
if (function_exists('ini_set')) {
ini_set('include_path', CAKE_CORE_INCLUDE_PATH .
PATH_SEPARATOR . ROOT . DS . APP_DIR . DS .
PATH_SEPARATOR .
ini_get('include_path'));
define('APP_PATH', null);
define('CORE_PATH', null);
} else {
define('APP_PATH', ROOT . DS . APP_DIR . DS);
define('CORE_PATH', CAKE_CORE_INCLUDE_PATH . DS);
}
}

Thanks and Regards
Vikram

On May 28, 4:52 am, brian <bally.z...@gmail.com> wrote:
> It looks like you've set the path somewhere with a semi-colon too
> many. htaccess, maybe? The value from ini_get('include_path') seems to
> have a semi-colon prepended.
>
> No, wait--you've got 2 colons separated by a period. Am I reading that
> correctly?
>
> What does the block starting with "if (!defined('CORE_PATH')) {" in
> webroot/index.php look like?
>
> On Wed, May 27, 2009 at 1:58 AM, ShiVik <vikramvmalhotra1...@gmail.com> wrote:
>
> > Hello there
>
> > This is the error that I am getting.
>
> > Failed opening required 'cake/bootstrap.php' (include_path='/webapp/
> > code/app1/cake:/webapp/code/app1/:.:/opt/lampp/lib/php') in /var/www/
> > webapp/htdocs/index.php on line 88
>
> > Thanks and Regards
> > Vikram
>
> > On May 27, 2:52 pm, Braindead <markus.he...@gmail.com> wrote:
> >> Are you sure that your problem is related to the PATH_SEPARATOR? I
> >> guess they use the constant PATH_SEPARATOR to make it work on Windows
> >> and Linux without having to worry about that.
> >> I also develop on Windows using XAMPP and my production server is on
> >> Linux. I never had that kind of problems.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: