I've installed the image module but I keep getting a "Directory does not exist" when it obviously does.

Comments

b_’s picture

Have a look at the image.module file, around line 722:

722: $image_path = file_create_path(file_directory_path() . '/' . variable_get('image_default_path', 'images'));

The pre-pending of file_directory_path() causes errors as the file_create_path() (file.inc, line 64) method implicitly uses file_directory_path().

This means that if you specify "images" as you image directory the file_directory_path() will be pre-pended giving "sites/default/files/images" and then this will be passed to file_create_path() which again pre-pends the file_directory_path() giving "sites/default/files/sites/default/files/images" which of course does not exist.

Possible Fix
Remove the initial "file_directory_path()" pre-pend to give:
722: $image_path = file_create_path(variable_get('image_default_path', 'images'));

Hope this makes sense.

g.s’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

sun’s picture

Version: 6.x-1.0-alpha3 » 6.x-1.0-alpha4
Assigned: g.s » Unassigned
Status: Closed (fixed) » Active
asespat’s picture

I have the same issue

this error appears

El directorio /tmp/image no existe.

The file does not exist

But the file exist

I use the last image module 6.10 - alpha4

any idea?

thanks

sun’s picture

Status: Active » Closed (duplicate)
benjaminwittenberg’s picture

I also had this issue.

The default image path "images/tmp" is incorrect. Change the default path to "sites/default/files/images/temp", and click "save configuration". Drupal should be happy now.