Okay, this is my structure:

domain.com/.htaccess

<IfModule mod_rewrite.c>
   RewriteEngine on
   RewriteBase /
   RewriteRule    ^$ app/webroot/    [L]
   RewriteRule    (.*) app/webroot/$1 [L]
</IfModule>

domain.com/app/.htaccess
<IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteBase /app/
    RewriteRule    ^$    webroot/    [L]
    RewriteRule    (.*) webroot/$1    [L]
 </IfModule>

domain.com/app/webroot/.htaccess
<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /app/webroot/
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^(.*)$ index.php?url=$1 [QSA,L]
</IfModule>

And it works fine for me. I have another site running cakephp as subdomain
like sub.domain.com and it points to domain.com/subdomainfolder, where i
cakephp app.
There I have exactly the sam structure of .htaccess files, and it works
with no problems.



2012/9/27 Paul Willis <paul.wil...@me.com>

> I tried editing my .htaccess in domain.com/oursite/caketest/ but it made
> no difference.
>
> Are your other two .htaccess files set to the default without RewriteBase
> being set?
>
> Paul
>
>
> On 27 Sep 2012, at 16:38, Ivan Rimac <ivn...@gmail.com> wrote:
>
> > I had similar issue.
> >
> > You can try enter this into app/.htaccess file
> >
> > <IfModule mod_rewrite.c>
> >    RewriteEngine on
> >    RewriteBase /
> >    RewriteRule    ^$ app/webroot/    [L]
> >    RewriteRule    (.*) app/webroot/$1 [L]
> > </IfModule>
> >
> > And check if there is on your Auth component allowed to display home
> page.
> >
> > Hope this helps,
> > Cheers
> >
> >
> >
> > 2012/9/27 Paul Willis <paul.wil...@me.com>
> > Hi
> >
> > I can't get a brand new CakePHP installation working on a customer's
> server. The details of what is going on are below, including everything
> I've tried, but my conclusion is that it is probably something as simple as
> AllowOverride isn't set to 'all'. The guys who run the server only take
> instructions from the customer via a ticket system (fair enough) so it is a
> slow operation to get changes made or details of configs out of them etc.
> I'd like to have some facts to approach them with rather than go fishing.
> Is there something I can do to test this?
> >
> > The details….
> >
> > We are creating a mini site within a subfolder on a customer's
> Apache/2.2.16 server. Their main website runs on...
> >
> > domain.com/
> >
> > We have been given access to a subfolder...
> >
> > domain.com/oursite/
> >
> > I dropped a basic phpinfo() index.php into the subfolder, surfed in and
> it displays fine. PHP 5.3.3 is installed and processes the page.
> >
> > phpinfo() suggests that the actual path to our folder is…
> >
> > /var/www/oursite
> >
> > I then dropped a cake php installation into the subfolder all contained
> in a directory called 'caketest'. This is basically an unstuffed download
> of CakePHP 2.2.2 but when I go in my browser to...
> >
> > domain.com/oursite/caketest/
> >
> >
> >
> > If I go to...
> >
> > domain.com/oursite/caketest/app/webroot/
> >
> > I see a Cake error page (with no CSS)…
> >
> >         Missing Method in AppController
> >         Error: The action webroot is not defined in controller
> AppController
> >
> > Following the advanced installation suggestions on
> http://book.cakephp.org/2.0/en/installation/advanced-installation.html
> >
> > I've tried uncommenting the line…
> >
> >         define('CAKE_CORE_INCLUDE_PATH', ROOT . DS . 'lib');
> >
> > ..in app/webroot/index.php
> >
> > I've tried defining the paths manually in app/webroot/index.php…
> >
> >         define('ROOT', DS . 'var' . DS . 'www' . DS . 'oursite');
> >         define('APP_DIR', 'caketest');
> >         define('CAKE_CORE_INCLUDE_PATH', DS . 'var' . DS . 'www' . DS .
> 'oursite' . DS . 'caketest' . DS . 'lib');
> >
> > I've tried adding…
> >
> > RewriteBase /var/www/oursite/caketest
> >
> > ...to each of the three .htaccess files with no change in the results.
> >
> > Nothing makes any difference to my results so any suggestions gratefully
> received
> >
> > Cheers
> >
> > Paul
> >
> > --
> > Like Us on FacekBook https://www.facebook.com/CakePHP
> > Find us on Twitter http://twitter.com/CakePHP
> >
> > ---
> > 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+unsubscr...@googlegroups.com.
> > Visit this group at http://groups.google.com/group/cake-php?hl=en.
> >
> >
> >
> >
> >
> >
> > --
> > Ivan Rimac
> > mail: ivn...@gmail.com
> > tel: +385 95 555 99 66
> > http://ivanrimac.com
> >
> >
> > --
> > Like Us on FacekBook https://www.facebook.com/CakePHP
> > Find us on Twitter http://twitter.com/CakePHP
> >
> > ---
> > 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+unsubscr...@googlegroups.com.
> > Visit this group at http://groups.google.com/group/cake-php?hl=en.
> >
> >
>
> --
> Like Us on FacekBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> 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+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>


-- 
*Ivan Rimac***
mail: ivn...@gmail.com
*tel: +385 95 555 99 66*
*http://ivanrimac.com*

-- 
Like Us on FacekBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

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


Reply via email to