Thursday, May 23, 2013

How to force the cakephp app work in http://mysite.com/app/webroot/

I have a cakePHP app in /app/webroot,
/app/.htaccess:
AddDefaultCharset utf-8

AddCharset utf-8 *

<IfModule mod_charset.c>

CharsetSourceEnc utf-8

CharsetDefault utf-8

</IfModule>
<IfModule mod_rewrite.c>
   
   RewriteEngine on
   RewriteBase /app/webroot/
   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteCond %{REQUEST_FILENAME} !-d
   RewriteRule    ^$    /app/webroot/    [L]
   RewriteRule    (.*) /app/webroot/$1    [L]
   #rewritecond %{REQUEST_URI} ^/(phpMyAdmin|fm)/
   #RewriteRule .* - [S=2]
   #RewriteRule    ^$ app/webroot/    [L]
   #RewriteRule    (.*) app/webroot/$1 [L]
   #RewriteRule ^(.*)$ index.php?route=$1 [L,QSA]
   #RewriteRule index.php index.php [L]
   RewriteRule ^(.*)$ index.php?route=$1 [L,QSA]
</IfModule>

and '/app/webroot/.htaccess:'

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

DirectoryIndex index.html

It is not workin in http://mysite.com/app/webroot/

How to force site work?

--
Like Us on FaceBook 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 unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscribe@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

No comments: