In my CCK image_url field, the "link to provider" in full node view is not working when I updated the emfield. I am not exactly sure since when its not working, but it used to work I guess 3 updated ago. Any help will be much appreciated.

CommentFileSizeAuthor
#3 emimage-links.patch1.1 KBgilgabar

Comments

Plazmus’s picture

Version: 6.x-1.15 » 6.x-1.17

Yes, there is definitely something wrong.
For me it looks like 'Image Preview Settings' is overwriting 'Full size display settings' and 'Thumbnail'.
It is not possible to set thumbnail to be linked to content and full size image to provider at the moment, you can only have both linked to content or both linked to provider.

Plazmus’s picture

Category: support » bug

It's definitely a bug.

gilgabar’s picture

Status: Active » Needs review
StatusFileSize
new1.1 KB

The problem is in emimage.theme.inc. It looks like a sloppy copy/paste job. The same line that is appropriate for theming preview links is used for full and thumbnail links as well.

$link = isset($options['preview_link']) ? $options['preview_link'] : $field['widget']['preview_link'];

It's pretty straightforward to fix. Just change the word 'preview' to 'full' or 'thumbnail' in each place. Patch attached.

heyqule’s picture

Hey gilgabar

Your patch is giving "patch unexpectedly ends in middle of line" error because it's missing a return character at end of file.

After adding that return character, the patch worked and it solved the issue for me.

aaron’s picture

Status: Needs review » Fixed

fixed. thanks @gilgabar.

Status: Fixed » Closed (fixed)

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