Friday, January 29, 2010

RE: Localsite Virtual Setup

Perfect that's what I was looking for. 1 cake for many sites.

Thanks I will give that a try. I have the virtual hosts all set up using
Apache. Its just a pain having to copy cake folders / upgrade them when I
can do it this way once.

Good looking out!

Thanks,

Dave

-----Original Message-----
From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
Of Bryan De Asis
Sent: January-29-10 2:46 PM
To: cake-php@googlegroups.com
Subject: Re: Localsite Virtual Setup

In order for you to setup that kind of structure you need to follow this
structure.

www/
lib/ -- putting all the cakephp versions you can
dump any version of cake here for reference
cakephp1.2.5/
cake/
vendors/
.htaccess
index.php

site1/
app/

site2/
app/

site3/
app/

you need to edit the following files:

/site1/app/webroot/index.php
/site2/app/webroot/index.php
/site3/app/webroot/index.php

change the following lines to

/site1/app/webroot/index.php

if (!defined('ROOT')) { define('ROOT', DS.'www'.DS.'site1'); } if
(!defined('APP_DIR')) { define('APP_DIR', 'app'); } if
(!defined('CAKE_CORE_INCLUDE_PATH')) {
define('CAKE_CORE_INCLUDE_PATH',DS.'www'.DS.'lib'.DS.'cakephp1.2.5'); }

/site2/app/webroot/index.php

if (!defined('ROOT')) { define('ROOT', DS.'www'.DS.'site2'); } if
(!defined('APP_DIR')) { define('APP_DIR', 'app'); } if
(!defined('CAKE_CORE_INCLUDE_PATH')) {
define('CAKE_CORE_INCLUDE_PATH',DS.'www'.DS.'lib'.DS.'cakephp1.2.5'); }


/site3/app/webroot/index.php

if (!defined('ROOT')) { define('ROOT', DS.'www'.DS.'site3'); } if
(!defined('APP_DIR')) { define('APP_DIR', 'app'); } if
(!defined('CAKE_CORE_INCLUDE_PATH')) {
define('CAKE_CORE_INCLUDE_PATH',DS.'www'.DS.'lib'.DS.'cakephp1.2.5'); }

I hope this one will help..

you can add as many site as you want...


On Fri, Jan 29, 2010 at 11:57 AM, Dave <make.cake.bake@gmail.com> wrote:


I want to set up my virtual environmant so i can use 1 copy of Cake
and all
site being developed can use that 1 copy.

So i currently have my www folder
www/
site1/
app/
cake/

site2/
app/
cake/


site3/
app/
cake/

But this is not the obvious setup.

I would much preffer

Www/
cake/
site1/ (would site1 just be renaming app folder to site1?)
site2/
site1/

What would I need to change to get this type of set up running? Just
the
htaccess? Or do I need to do anything with cake also?

Thanks

Dave

Check out the new CakePHP Questions site http://cakeqs.org and help
others with their CakePHP related questions.

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
<mailto:cake-php%2Bunsubscribe@googlegroups.com> For more options, visit
this group at http://groups.google.com/group/cake-php?hl=en


Check out the new CakePHP Questions site http://cakeqs.org and help others
with their CakePHP related questions.

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
cake-php+at http://groups.google.com/group/cake-php?hl=en


Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

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: