How to solve cakephp 500 Internal Server Error?

微笑、不失礼 提交于 2019-12-24 11:44:02

问题


I built a tiny application for a client using cakephp on my local machine running xampp over windows [in a folder "cake" inside htdocs]. Today i created a new folder on my client's live server named "cake" and uploaded the contents of "cake" folder on local machine to "cake" folder on live server for testing. I fired up my app using url: http://kianaretail.com/cake and I got an internal server error 500.

I went through several people suggesting addition of RewriteBase to .htaccess files in root, app and webroot folders pointing to the location. In my case it was "RewriteBase /cake" in root, "RewriteBase /cake/app" in app and "RewriteBase /cake/app/webroot" in webroot. But it did not work still. The problem still persists.

The same application runs fine on my local machine. Just messes up on live server.

Please help.


回答1:


if the application runs fine in the local machine but has problems in the live server, you could also try to investigate which configurations are different between the servers to try to get some hints as to what might be causing the problem.

I would guess that the live server doesn't have mod_rewrite enabled, and so a .htaccess with RewriteBase could be causing the trouble. You can try to comment the .htaccess and see if it runs fine in the server and then re-enable the configurations one at a time to try to figure things out.

Also, as Dave mentioned, checking the error logs would probably give you more information as well.

Hope that helps.



来源:https://stackoverflow.com/questions/19893132/how-to-solve-cakephp-500-internal-server-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!