I installed image api, activated it, the I installed imagecache 2.0 beta, activated it and soon I click "Save Configuration" on the module page, I get a white screen. Only way to get my site back is to delete the imagecache folder.

Comments

Triskelion’s picture

Component: Miscellaneous » Code
Assigned: Unassigned » Triskelion

I got the same thing. Server is throwing the following fatal PHP error (I have Thickbox installed):

Call to undefined function _imagecache_get_presets() in ....... thickbox.module Line 157.

greg@beargroup.com’s picture

If you can get into your apache error logs, you should be able to see what caused the issue. I had this happen at first and it was because I had used Lullabots tutorial some ages ago for imagecache_profiles and there was some functions in there added to template.php that had the same namespace. Anyway - look in the error log on your webserver, and you should be able to pinpoint what is causing the fatal php error.

softtouch’s picture

Same happen if lightbox is installed: _imagecache_get_presets() fatal error.
Seems like thickbox and lightbox need to be updated, and not imagecache...

dopry’s picture

Status: Active » Closed (fixed)

Lightbox and Thickbox do not work with imagecache 2.x yet. They will need to be updated... If you're so inclined you can open issues in both their issue queues... I cannot easily reassign this ticket to two other projects queue....

.darrel.

greg@beargroup.com’s picture

I also just reproduced this error by having a slightly older version of CCK's imagefield installed . It also is calling _imagecache_get_presets() which doesn't exist anymore in 2.0 - probably should be in the docs that modules that use imagecache (lightbox, imagefield... others) need to be upgraded to compatible versions (I think it is in the download page). Or just add the function back in to image_cache and pass it through to the new one for compatibility if that's possible.

[client] PHP Fatal error: Call to undefined function: _imagecache_get_presets() in /var/www/vhosts/q.com/httpdocs/modules/cck/imagefield/imagefield.module on line 563

scottrigby’s picture

Thickbox module patch works for me – see #7 at this issue here: #205420: Compatibility with ImageCache 5.x-2.x
:)
Scott

lipilee’s picture

starting out from the Thickbox patch, I simply changed line 133 of cssk_slideshow.module from

'#options' => array('' => 'Full size image') + drupal_map_assoc(_imagecache_get_presets()),

to

'#options' => array('' => 'Full size image') + drupal_map_assoc(imagecache_presets()),

is there anything else I need to do? now I get 2 warnings:

* warning: Illegal offset type in [drupal path]/includes/common.inc on line 1323.
* warning: Illegal offset type in [drupal path]/includes/common.inc on line 1323.

and that's about as far as my php knowledge goes :)