Updated to comply with following changes:

  1. function _imagecache_get_presets() was renamed to imagecache_presets().
  2. structure of the array returned by above function has changed.

(see attached)

Comments

ms2011’s picture

StatusFileSize
new636 bytes

whoops, there's one more...

ms2011’s picture

Category: bug » feature
StatusFileSize
new854 bytes

found another part that will need to be updated.

(see attached)

also, this is probably more of a feature request.

dsnydernc’s picture

Does this last patch include the previous two?

ms2011’s picture

No. Apply each one in order.

miro_dietiker’s picture

I'd love to see some information about the need of this patch when using ThickBox with ImageCache 5.x-2.x.
Or any further compatibility note "Use ImageCache xxx for this component". This would allow new users a much smoother way to use this component - without pitfalls.

Thanks!

brunodbo’s picture

Status: Active » Needs review
dopry’s picture

StatusFileSize
new1.41 KB

Here is a composite patch for the module. Also note that imagecache generated image links now have several classes applied to the tag so you can also target them via JS for thickboxing.

ex)
$(document).ready(function(){
tb_init('a.imagecache-imagelink');//pass where to apply thickbox
imgLoader = new Image();// preload image
});

frjo’s picture

Assigned: Unassigned » frjo

Thanks a lot for this patch, I will soon commit it to 5-dev and the upcoming 6-dev.

vito_swat’s picture

Patch in #7 doesn't work for me.

{edit}
My bad it's working.

sun’s picture

Status: Needs review » Reviewed & tested by the community

Confirming, this patch fixes fatal errors with ImageCache 5.x-2.x.

splash112’s picture

As I'm a total disaster in patching....
Could somebody maybe upload the new DEV version, or just the updated module?

Thanks!

tanjerine’s picture

hi, just wanted to let you know that the patch in comment#7 brought back my site from the white screen (of death). have yet to play with the site, but at least there's something there to play with now, instead of just a blank white sceen.

thanks!

hanoii’s picture

StatusFileSize
new1.95 KB

Applied patch #7 and worked OK.

There's an addition, though, that worth including. Attaching the patch (patch of #7 is also included so should only applied this patch if interested).

Basically as imagecache2 now doesn't have clean urls as a requirement, I change the theme function so it uses the imagecache_create_url() function when creating the image to be displayed.

What I also think it should be added to this fixes before commiting is some kind of backward compatibility to imagecache 1.x so this module works for both versions.

dopry’s picture

I personally like an new release of lightbox that drops imagecache 1.x support, since I will probably not be providing support for imagecache 1.x in the near future.... forget backwards compatibility... drive people to upgrade... I don't like maintaining my ugly code, thats why I wrote a new version.

sun’s picture

@dopry: Agreed. However, after applying the patch, I needed to save all field display settings again. Is there a convenience function in ImageCache that could be used by other contrib modules in hook_update_N() to upgrade existing CCK field formatters to the new version?

dopry’s picture

hmm.. I think clear_cache_all() should do it.. I don't know that I had that problem.... but then again I'm bad about telling people to dump their cache. ;)

scottrigby’s picture

patch in #7 cleared up my white screen issue too. feels almost redundant to say "it works!", but hey – community tested, right? Thanks!

frjo’s picture

Version: master » 5.x-1.x-dev
Status: Reviewed & tested by the community » Fixed

Committed to 5-dev and to 6-dev, thanks!

senpai’s picture

Which patch was committed? #7 or #13?

frjo’s picture

I used the patch from #13.

Is the 5-dev version working OK? If it is I will make a official release.

sun’s picture

FYI: #259471: Update for ImageCache 2 API contains a patch that keeps compatibility with ImageCache v1 API.

Anonymous’s picture

Status: Fixed » Closed (fixed)

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