Hi,

great idea for a module, thanks for contributing this.

I just tried installing it and got the following error message:

Cannot redeclare _image_filename() (previously declared in /sites/all/modules/image/image.module:994) in /sites/all/modules/imagefield_import/imagefield_import.module on line 400

Tried uninstalling the image.module, but, the import_imagefield.module is dependent on the image.module

just thought I'd flag this in case you accidentally comitted the wrong module file.

Comments

Phillip Mc’s picture

Assigned: Unassigned » Phillip Mc
Priority: Critical » Minor
Status: Active » Closed (fixed)

D'oh! just realised the module requires the image add-on module for cck.module not the image.module.

Closing this.

1kenthomas’s picture

Version: 5.x-1.0-beta » 5.x-1.2-beta
Assigned: Phillip Mc » Unassigned
Status: Closed (fixed) » Active

It's still an issue because an existing site may have image and imagefield installed. Attempting rename of fn... Simply renaming the colliding function seems to solve the conflict.

Anyone know a reason not to :S?

plasticlax’s picture

yeah i am not even sure how you disable image module when this error is site-wide and prevents you from loading the modules page.

plasticlax’s picture

i renamed the fn too and now everything works.

vordude’s picture

Status: Active » Fixed

The function is renamed in the latest releases for both 5.x and 6.x

Status: Fixed » Closed (fixed)

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

freatida’s picture

Version: 5.x-1.2-beta » 5.x-1.4
Status: Closed (fixed) » Active

I had the same problem when installing v 1.4. The fn hasn't been renamed in this version.

rhimes’s picture

Priority: Minor » Critical

ditto #7, ver 1.4 still has:
" function _image_filename($filename, $label = IMAGE_ORIGINAL, $temp = FALSE) { "
and:
" if (!file_copy($filepath, _image_filename($filepath, IMAGE_ORIGINAL, TRUE))) { "

in addition, shouldn't:
" $path = variable_get('image_default_path', 'images') .'/'; "
be instead :
" $path = variable_get('imagefield_default_path', 'images') .'/'; "

wulff’s picture

Status: Active » Fixed

This has been fixed in version 5.x-1.5.

Status: Fixed » Closed (fixed)

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