Nickool
Nickool

Reputation: 3702

problem installing CakePHP on Linux

I have downloaded the CakePHP from it's site then I copied the files in srv/www/htdocs renamed the folder to first_app

Here is the output(error and warnings that shows me):

Release Notes for CakePHP 2.0.0-dev.

Fatal error: Class 'Debugger' not found in /srv/www/htdocs/first_app/cake/libs/view/pages/home.ctp on line 26

also the tutorial tells me that I must have this:

Apache server with mod_rewrite

I didn't know how to find it and install it?

is that causing this problem?

I want to know how to add "another" root without having problem

I used this and no result:

<Directory /srv/www/htdocs/first_app/app/webroot>
    Options None
    AllowOverride All
    Order deny,allow
    Deny from all
</Directory>

also I changed the /etc/apache2/server-default.conf

I changed allow override None to Allow override All in the part of this:

<Directory "/srv/www/htdocs">

Upvotes: 2

Views: 3203

Answers (3)

Arjan
Arjan

Reputation: 9874

chmod -R 0777 /srv/www/htdocs/first_app/app/tmp/

This makes the tmp dir writable for everybody (on your machine) so also for the web server. If you want to limit access, first try this, then browse to your CakePHP install, and then check in the cache dir which files have been created and what's the owner and group of those files.

The tmp dir contains more than just the cache dir, it also contains sessions and logs. Anything outside of /srv/www/htdocs/first_app/app/tmp/ does not need to be writable for the server, anything inside that folder should be writable.

The default CakePHP install comes with .htaccess files. You do need those files. They redirect every request to localhost/first_app (or any other dir your is installed in) into the webroot, so you don't have to do that yourself. You need to have AllowOverride All in your apache config. See here for instruction on how to enable that.

Upvotes: 2

Josh Sherick
Josh Sherick

Reputation: 2161

same problem on mac. on mac, i just right clicked on the directory it was concerned about and changed the permissions so that everyone could read/write, and clicked apply to enclosed files/folders.

I used to use linux but i'm not sure exactly how to do this, but hopefully this will get you on the right track? i assume that the command you posted changes the permissions of that folder, but maybe you need to change the permissions of the files and folders inside.

Upvotes: 0

Related Questions