开发者

cakePHP - project was working on localhost but not on website

I have some project in cakePHP which was working on localhost but when I deployed it on internet its not working ... I feel theere is some issue with .htaccess.. Please help. Thanks in advance

content of my htaccess

<IfModule mod_rewrite.c>
    RewriteEngine  on
    RewriteRule  favicon\.ico$  f开发者_如何学JAVAavicon.ico  [NC,L]
    RewriteRule  (img|css|js|files|stats)/(.*)$  $1/$2  [NC,L]
    RewriteCond  %{REQUEST_FILENAME} !-d
    RewriteCond  %{REQUEST_FILENAME} !-f
    RewriteRule  ^(.*)$  index.php?url=$1  [QSA,L]
</IfModule>


I assume this is a shared hosting environment. I would recommend deploying without .htaccess rewriting support and see if things work. You can find the configuration in app/config/core.php.

 /**
 * To configure CakePHP *not* to use mod_rewrite and to
 * use CakePHP pretty URLs, remove these .htaccess
 * files:
 *
 * /.htaccess
 * /app/.htaccess
 * /app/webroot/.htaccess
 *
 * And uncomment the App.baseUrl below:
 */
Configure::write('App.baseUrl', env('SCRIPT_NAME'));
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜