Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Drupal 7 error: The file could not be created

Tags:

php

drupal-7

I move drupal 7 from server(live Site) to my localhost(xampp). I change settings.php(files/defualt/settings.php) for database connection and remove cache from mysql database. now in load index, i see my website without css design(only text) and see this error :

**Error message**:
The file could not be created.
The file could not be created.
The file could not be created.
The file could not be created.
The file could not be created.

I think drupal not create css/js compression files. How To Fix This Error? Thanks For Any Help.

like image 412
BaTmaN Avatar asked Nov 17 '12 22:11

BaTmaN


3 Answers

While running MAMP

found answer from here: http://drupal.org/node/581558#comment-6202892

Went to: admin/config/media/file-system

changed "/tmp/php" to "tmp/php" and problem was solved.

like image 177
Martin Sookael Avatar answered Sep 21 '22 00:09

Martin Sookael


similar to the other answer it was a problem with my file system setup. The tmp directory in my live site is in a folder outside the public_html folder.

  • so I just created a new tmp directory inside my directory structure and
  • went to admin/config/media/file-system and
  • set the tmp folder to point to that new tmp folder.
like image 32
Japo Domingo Avatar answered Sep 19 '22 00:09

Japo Domingo


It seems a permissions problems, after you cleared the drupal cache, all the css and js files needs to be recreated in sites/default/files (or sites/yourdomain/files), check the web users has permission to write in this directory.

like image 21
m4t1t0 Avatar answered Sep 21 '22 00:09

m4t1t0