I am working on website having front website made with WordPress and a WordPress directory
contains a dashboard folder having a cakephp website. Everything is working perfectly on my
local system but when I migrated the whole website to online server I am unable to access
www.mywebsite.com/dashboard folder as I read here
this is a htaccess issue but I dont know htaccess coading at all so this link was confusing
to me if any one could explain me (in simple way) why this problem occurs? and how to
solve this problem? will be helpfull to me
my wordpress htaccess is
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
and cakephp htaccess which is in wordpress-install-directory/dashboard/cakephp-install
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^$ webroot/ [L]
RewriteRule (.*) webroot/$1 [L]
</IfModule>
It should be just a case of changing your .htaccess to match the below
Doing the above will tell cake that the needed files are within instal-directory/dashboard.
You will also need to make the same change to webroot and app .htaccess
If they are in different folders with independent .htaccess files, you might try to set the base directory for cakephp, like this:
From a stackoverflow answer here:http://stackoverflow.com/questions/2322559/htaccess-wordpress-exclude-folder-from-rewriterule/2350305#2350305
add
before the last RewriteRule on your .htaccess file on wordpress directory and it should work.